Sign in to follow this  
Followers 0
socceraddict

MS Word Form Letter Help Needed

4 posts in this topic

#1 ·  Posted (edited)

I'm looking for a method to populate a form letter with data from stored variables.

Here's a piece of my form letter...

zfirstname zlastname

zstreet

zcity, ID zzipcode

Dear zsal zlastname:

I've tried to use the following code to find and replace, but when I paste the variable into the replace text box, it seems to be including an <ENTER> too. Is there a more efficient way of populating a form letter with variables from my script?

WinActivate("life quote letter_variables.doc - Microsoft Word")

WinWaitActive("life quote letter_variables.doc - Microsoft Word")

send("^h")

WinWaitActive("Find and Replace")

send("zfirstname{tab}")

send($firstname)

Thanks for the help

Edited by socceraddict

Share this post


Link to post
Share on other sites



OK, I figured it out. I just added the following code...

send("{esc}")

send("{tab 2}a")

send("{enter}")

However, is there a more efficient way of populating a form letter?

Share this post


Link to post
Share on other sites

My Word Automation Library should make easy work of this. The link is in my signature and you will also find a help file with examples of its use.

Share this post


Link to post
Share on other sites

Thanks. I'll take a look.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0