M
millahtime
I have some code that worked in Word 97 but not in Word XP. The proble
seems to be with my selection.find.execute
The code is like:
While Selection.Find.Execute
Selection.TypeText Format(BlkNo)
BlkNo = BlkNo + 1
Wend
The code here just replaces a block number. The number keep
increasing by 1 each time and it goes throught the whole document unti
it hits the end replacing the old numbers with new numbers. When it'
found the last one it stops (in word 97)
The problem is that the Selection.Find.Execute never ends in Word X
and just keeps finding the last point and adding a number to it. Thi
goes on until you end task to the program.
Is there a way to get the selection.find.execute to stop doing tha
when it has found the last point in the document? Or another easy wa
to do this
seems to be with my selection.find.execute
The code is like:
While Selection.Find.Execute
Selection.TypeText Format(BlkNo)
BlkNo = BlkNo + 1
Wend
The code here just replaces a block number. The number keep
increasing by 1 each time and it goes throught the whole document unti
it hits the end replacing the old numbers with new numbers. When it'
found the last one it stops (in word 97)
The problem is that the Selection.Find.Execute never ends in Word X
and just keeps finding the last point and adding a number to it. Thi
goes on until you end task to the program.
Is there a way to get the selection.find.execute to stop doing tha
when it has found the last point in the document? Or another easy wa
to do this