Please Help!! Insert Query to Bookmark in Word Document

A

A. Smart

I have a table with a list of jobs with each job there are a number of parts.
I have created a query to show the parts for a particular job, I would like
this query to be inserted into a bookmark in a word template I have made.
I currently use a command button to insert fields from a form to this blank
template and would like to include this query aswell, How do I go about it?

General Code for inserting into bookmarks (Command button):

.ActiveDocument.Bookmarks("JobNo").Select
.Selection.Text = (CStr(Me.Job_No))
'Field
.ActiveDocument.Bookmarks("JobTitle").Select
.Selection.Text = (CStr(Me.Job_Title))
'Field
.ActiveDocument.Bookmarks("WorkStation").Select
.Selection.Text = (CStr(Me.Work_Station)) 'Field
.ActiveDocument.Bookmarks("IssueNo").Select
.Selection.Text = (CStr(Me.Issue_No))
'Field
.ActiveDocument.Bookmarks("IssueDate").Select
.Selection.Text = (CStr(Me.Issue_Date))
'Field
.ActiveDocument.Bookmarks("PartsRequired").Select
.Selection.Text = (CStr(Me.Query???????))
'Query??????
.Activate
 

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

Top