R
Rodney Dangerfield
Hi. I'm new to VB. Can anyone help me out? (I don't get no respect. No
respect at all!)
I've got a simple Microsoft Word macro (see below) that inserts quotation
marks at the start and end of a line of text. For instance, it will change:
my line of text
into . . .
"my line of text"
But now I've got a document with about 400 lines of text.
So I need to have the macro LOOP (is that what it's called?) . . . so it
keeps REPEATING ITSELF until it reaches the BOTTOM of the Word document.
Then it stops.
I realize this is probably an easy question for most folks in this group . .
.. I'm grateful for your help. - Jim
HERE'S THE MACRO:
Sub InsertQuotes()
'
' InsertQuotes Macro
' Macro recorded 11/16/2004 by Jim
'
Selection.TypeText Text:=""""
Selection.EndKey Unit:=wdLine
Selection.TypeText Text:=""""
Selection.MoveRight Unit:=wdCharacter, Count:=1
End Sub
respect at all!)
I've got a simple Microsoft Word macro (see below) that inserts quotation
marks at the start and end of a line of text. For instance, it will change:
my line of text
into . . .
"my line of text"
But now I've got a document with about 400 lines of text.
So I need to have the macro LOOP (is that what it's called?) . . . so it
keeps REPEATING ITSELF until it reaches the BOTTOM of the Word document.
Then it stops.
I realize this is probably an easy question for most folks in this group . .
.. I'm grateful for your help. - Jim
HERE'S THE MACRO:
Sub InsertQuotes()
'
' InsertQuotes Macro
' Macro recorded 11/16/2004 by Jim
'
Selection.TypeText Text:=""""
Selection.EndKey Unit:=wdLine
Selection.TypeText Text:=""""
Selection.MoveRight Unit:=wdCharacter, Count:=1
End Sub