C
CY
Hi,
I have just inserted a simple textbox in Word.
The text box provides an avenue for me to type in the location of a textfile.
Textbox text would be C:\Temp\TEST in this case
Documents.Add
ChDir "C:\Temp\TEST"
myName = Dir("*.sum")
While myName <> ""
With Selection
Selection.TypeParagraph
.TypeText Text:="*******************************"
Selection.TypeParagraph
.TypeText Text:="Filename: " & myName
Selection.TypeParagraph
.TypeText Text:="*******************************"
Selection.TypeParagraph
Selection.TypeParagraph
.InsertFile FileName:=myName, ConfirmConversions:=False
.InsertParagraphAfter
.InsertBreak Type:=wdPageBreak
.Collapse Direction:=wdCollapseEnd
End With
myName = Dir()
Wend
Any help welcome
Cy
I have just inserted a simple textbox in Word.
The text box provides an avenue for me to type in the location of a textfile.
Textbox text would be C:\Temp\TEST in this case
Documents.Add
ChDir "C:\Temp\TEST"
myName = Dir("*.sum")
While myName <> ""
With Selection
Selection.TypeParagraph
.TypeText Text:="*******************************"
Selection.TypeParagraph
.TypeText Text:="Filename: " & myName
Selection.TypeParagraph
.TypeText Text:="*******************************"
Selection.TypeParagraph
Selection.TypeParagraph
.InsertFile FileName:=myName, ConfirmConversions:=False
.InsertParagraphAfter
.InsertBreak Type:=wdPageBreak
.Collapse Direction:=wdCollapseEnd
End With
myName = Dir()
Wend
Any help welcome
Cy