Automating data to export into a Word Merge Doc

G

Guest

I want to create a command button on my form to export data in the database
to a word doc. I'm not for sure on what docmd to use. Please help!!! Below is
what I have so far.

Public Sub SubLetters()
'Export Data to SubLetters

Dim strmsg As String
Dim strmsg As string1
strmsg = " Are you ready to import data to the Sub Letters?"
strmsg1 = "Export completed"

If MsgBox(strmsg, vbYesNo, "Export File") = vbYes Then
 
G

Guest

That works great expect for one thing that I may need help on. I have a
couple of queries that when you go to run the query, it prompts you for a box
to type in the date for a list of students who are to attend that training.
That is actually the query I need to Use, but when I go to try to merge that
query, it never prompts me for the box to enter my date, but instead tells me
that there is no data to merge. That only seems to be happening with that
particular query, the other query's with out any resctrictions runs great.
Here is the coad for that particular form:

Option Compare Database
Option Explicit

Private Sub Command2_Click()

MergeAllWord Me.Combo0

End Sub
Private Sub Command3_Click()
On Error GoTo Err_Command3_Click


DoCmd.Close

Exit_Command3_Click:
Exit Sub

Err_Command3_Click:
MsgBox Err.Description
Resume Exit_Command3_Click

End Sub

Thanks!!!
 
G

Guest

Hi

There "work-a-rounds" for most things. In this case you "could run a make
table query AfterUpdate - although may not work.

I think it would be a good idea to e mail Albert (address on his site) and
see if he has come accress this problem before
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top