473,320 Members | 1,746 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Access to Word Mail merge

on my database i have a customers Table (tblCustomers) on the form of
it (frmCustomers) i would like a button what will open up word and open

up my comapny letter head template and then merger the customer details

currently on the form into the Word letter so i can send an individual

letter.

Can any one help me
Thanks
Simon

Aug 7 '06 #1
5 2028
You are going to need a data source for your mail merge. I would
suggest a query that selects all the relevant information, but that
refers to your form for the correct CustomerID. In the criteria of the
CustomerId in the query, put Forms!frmCustomers!CustomerID. Did you
need help with setting up the actual document too or did you just not
know how to connect the data?
Simon wrote:
on my database i have a customers Table (tblCustomers) on the form of
it (frmCustomers) i would like a button what will open up word and open

up my comapny letter head template and then merger the customer details

currently on the form into the Word letter so i can send an individual

letter.

Can any one help me
Thanks
Simon
Aug 7 '06 #2
I would like to do something similar. I have done a simple mail merge
before and have set the data source to a table. How would Word know
what the resulting query would be if it depends on a drop down box on
an access form? I thought the data source was set pretty much at design
time...


Jeff L wrote:
You are going to need a data source for your mail merge. I would
suggest a query that selects all the relevant information, but that
refers to your form for the correct CustomerID. In the criteria of the
CustomerId in the query, put Forms!frmCustomers!CustomerID. Did you
need help with setting up the actual document too or did you just not
know how to connect the data?
Simon wrote:
on my database i have a customers Table (tblCustomers) on the form of
it (frmCustomers) i would like a button what will open up word and open

up my comapny letter head template and then merger the customer details

currently on the form into the Word letter so i can send an individual

letter.

Can any one help me
Thanks
Simon
Aug 7 '06 #3
I misinfomed you. The reference to the form cannot be used and I
thought that it could. You could run a make tbl query that creates
you record source for your mail merge. In that Make Tbl query you
could refer to the form to grab the person you need. Sorry about the
mixup.
CaptainDahlin wrote:
I would like to do something similar. I have done a simple mail merge
before and have set the data source to a table. How would Word know
what the resulting query would be if it depends on a drop down box on
an access form? I thought the data source was set pretty much at design
time...


Jeff L wrote:
You are going to need a data source for your mail merge. I would
suggest a query that selects all the relevant information, but that
refers to your form for the correct CustomerID. In the criteria of the
CustomerId in the query, put Forms!frmCustomers!CustomerID. Did you
need help with setting up the actual document too or did you just not
know how to connect the data?
Simon wrote:
on my database i have a customers Table (tblCustomers) on the form of
it (frmCustomers) i would like a button what will open up word and open
>
up my comapny letter head template and then merger the customer details
>
currently on the form into the Word letter so i can send an individual
>
letter.
>
Can any one help me
>
>
Thanks
>
>
Simon
Aug 7 '06 #4
"Jeff L" <jl*******@hotmail.comwrote in message
news:11**********************@m79g2000cwm.googlegr oups.com...
>I misinfomed you. The reference to the form cannot be used and I
thought that it could. You could run a make tbl query that creates
you record source for your mail merge. In that Make Tbl query you
could refer to the form to grab the person you need. Sorry about the
mixup.
Actually, I have a working example that automatically builds the merge based
on the current form.

This means that you can word-enable ANY form in your application with ONE
LINE of code, and the data source
for word will be setup for you auto-matic. This means my example solves 99%
of the merge issues that come up
when working with a application, and ANY form data can instantly be merged
to a word template with one line of
code (the default is to merge the CURRENT ONE record).

You can find this code example here:
http://www.members.shaw.ca/AlbertKal.../msaccess.html

The the above exmaple...it should solve both of your requests...

--
Albert D. Kallal (Access MVP)
Edmonton, Alberta Canada
pl*****************@msn.com
Aug 7 '06 #5
Your WordMailMerge is terrific, but how do I change the default data source
to a specific query (that contains information from two or three tables)?

Dec 25 '06 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Ecohouse | last post by:
I have a computer with XP on it. I loaded Office 97 first because I needed Access 97 for some work. I then loaded Office 2000. Everything seemed to be running fine. But I have come across a few...
9
by: Neil Ginsberg | last post by:
I have a strange situation using Access to automate a Word mail merge. Using Access 2000 and Word 2000, the code opens Word, opens the document in Word, sets a table in the calling Access...
3
by: Strasser | last post by:
In Access2000 mass emailing worked perfectly (very powerful tool!). Doesn't work when using XP version of both Access and Outlook, even though I checked the box to ensure that I was sending the...
3
by: Andy Davis | last post by:
I have set up a mail merge document in Word 2003 which gets its data from my Access 2000 database. I want to set up a button on a form that: 1. runs the query to provide the dat for the merge...
0
by: Linda Cacina | last post by:
Hello all you fine folks, Here is some code I am using to merge data from a single record Access 2K3 table into a NEW word document based on a pre-defined Word merge template doc. All I want to...
4
by: pmhaupt2 | last post by:
I developed an Access 2003 program that will allow the user to produce a group of Word letters that merge with data records from an Access database. I created a mail merge Word document and...
8
by: Ron B | last post by:
Help!!! What am I doing wrong? I am working with Office 2003 and am trying to create a command button on an Access form that will create a mail merge in Word from an Access table. I want to...
6
by: crealesmith | last post by:
Firstly, I have no problem with mail merging to Word, VB code for that works perfectly. On one mail merge I need to merge 15 fields of data that are from 3 seperate records. The 3 records are all...
1
by: Esther Lane | last post by:
Hello! First off, many many thanks to Albert who wrote the Mail Merge code for MS Access I am using. It has been working beautifully for a few years. However, my client just (without notice!)...
1
by: kayberrie | last post by:
I want to write a VBA mail merge code. I want to link the code/macro/dohicky to a nifty little button so it makes life easy. I think I can handle the button part, the code part - not so much. I know...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.