W
Webtechie
Hello,
I have three letters that I need to send out on a regular basis. I want to
have an Office application (Excel) call the word document and fill in the
Company name and address.
I need to have a Word VBA macro that can receive parameters and then
substitute them in a document. I know Excel VBA very well, but not sure how
to do this in Word.
Question
======
How do you write a Word VBA Macro that can receive parameters and then
subtitute fields in a document with the parameter values?
For example:
(Word VBA)
Sub ChangeAddress(byRef CompanyName as string, Address as string, city as
string, st as string, zip as string)
--Open the Word Document
--Take these parameters and substitute them in the Word document.
--Close the Word Document
End Sub
Thank you.
Tony
I have three letters that I need to send out on a regular basis. I want to
have an Office application (Excel) call the word document and fill in the
Company name and address.
I need to have a Word VBA macro that can receive parameters and then
substitute them in a document. I know Excel VBA very well, but not sure how
to do this in Word.
Question
======
How do you write a Word VBA Macro that can receive parameters and then
subtitute fields in a document with the parameter values?
For example:
(Word VBA)
Sub ChangeAddress(byRef CompanyName as string, Address as string, city as
string, st as string, zip as string)
--Open the Word Document
--Take these parameters and substitute them in the Word document.
--Close the Word Document
End Sub
Thank you.
Tony