Form Letters

N

Ngan Bui

I have Office XP with W2K.

Instead of using a mail merge, I created a function that
allows the user to send the current record to a Word
template. The data are name, address, zip, and 3 memo
fields that become 3 paragraphs in the letter. The user
views the letter and prints it out. They close the
template without saving.

The problem I have is the group of people who views these
letters tend to have more problems than those who don't
view the letters. For instance, they notice that the time
it takes to view the letter in Word is longer in the
afternoon than in the morning. Once in awhile, after they
close out of the db, the MS access encountered an error
msg comes up.

I haven't heard from anyone else with these constant
problems. I'm wondering if the viewing letters in Word
would be an issue. Is it better to have the letter as a
Access report, the way I have it now, or do a mailmerge?

Below is my function:

Dim objWord As Word.Application
Dim wdDoc As Word.Document
filepath = "O:\Databases\Documents\Complaints\"
strDocName = "CompResponse" & F!LetterVersion & ".dot"

' Start Microsoft Word.
Set objWord = CreateObject("Word.Application")
Set wdDoc = objWord.Documents.Add(filepath & strDocName)

objWord.Visible = True
wdDoc.Activate

With wdDoc
' Insert text from the form into each bookmark.
.Bookmarks("FirstName").Range.Text = F2!FirstName
.Bookmarks("LastName").Range.Text = F2!LastName
.Bookmarks("Address").Range.Text = F2!Address
.....
End With

Set wdDoc = Nothing
Set objWord = Nothing
Exit Sub
 
Top