ApplyBulletDefault不应用于Do-Loop

我在Excel中工作,填写一个单词模板(以前从来没有这样做过)。
首先,我正在search特定条目的列,然后创build一个具有行特定值的bulletpoint。 这里是代码:

With wd.Selection .GoTo what:=wdGoToBookmark, Name:="launches" 'Loop until cycled through all unique finds Do Until foundCells Is Nothing .Range.ListFormat.ApplyBulletDefault '<----- this doesn't work 'Find next cell with value Set foundCells = Sh.Columns(2).FindNext(After:=foundCells) Name = foundCells.Offset(0, 3).Value & Chr(11) action = foundCells.Offset(0, 5).Value & Chr(11) .TypeText (Name & " " & action) 'Test to see if cycled through to first found cell If foundCells.Address = FirstFound Then Exit Do Loop End With 

正如我所描述的,我想为每个细胞find一个符点。 但是突出显示的行在Do循环中不起作用,但在循环外部工作…问题在哪里?

编辑 :在进入上面之前,我正在做以下检查不存在的值:

 Set foundCells = Sh.Columns(2).Find(what:=month) 'Test to see if anything was found If Not foundCells Is Nothing Then FirstFound = foundCells.Address Else GoTo NothingFound End If 

所以不应该有任何关于不存在的价值问题(我希望)

你可以试试这个,告诉我它是否有效?

 With wd.Selection .GoTo what:=wdGoToBookmark, Name:="launches" .Range.ListFormat.ApplyBulletDefault '<----- this doesn't work 'Loop until cycled through all unique finds Do Until foundCells Is Nothing 'Find next cell with value Set foundCells = Sh.Columns(2).FindNext(After:=foundCells) Name = foundCells.Offset(0, 3).Value & Chr(11) action = foundCells.Offset(0, 5).Value & Chr(11) .TypeText (Name & " " & action & vbNewLine) 'Test to see if cycled through to first found cell If foundCells.Address = FirstFound Then Exit Do Loop End With