i have this invoice template and i want to fill this data like business name contact number
i have to fill this template ..and my approach is using scripts will can do this and i need the best approach for this
i tried vb script
i used this code but this is replacing only single text i want replace multiple text
'declare and instaciate wrdApp
Dim wrdApp: Set wrdApp = WScript.CreateObject("Word.Application")
'declare wrdDoc
Dim wrdDoc
Dim wdReplaceAll
'Open the document
Set wrdDoc = wrdApp.Documents.Open("C:\Temp\test\test.doc")
'set the value for the replace "constant"
wdReplaceAll = 2
wrdDoc.Select
With wrdApp.Selection.Find
.ClearFormatting
.Replacement.ClearFormatting
.Text = "aaa"
.Replacement.Text = "bbb"
.Forward = True
.Wrap = 1
.Format = False
.MatchCase = False
.MatchWholeWord = False
'the Replace argument is the 11'th argument
.Execute , , , , , , , , , , wdReplaceAll
End With
'clean up
Set wrdApp = Nothing
Set wrdDoc = Nothing

Report
All responses (
Answers (