Send mass emails of different pages to different addresses

grenee

Registered User.
Local time
Today, 15:04
Joined
Mar 5, 2012
Messages
212
How can individual invoices be sent to their repective email addresses without sending the entire list of invoices to each email address?
 
It depends on how you have your database set up and how you are sending emails? Are you just trying to output report results by customer and then you are manually emailing that document? Or do you have email automated within your database. Need more information.


http://www.accessmssql.com/
 
I have a table of 'customers' with fields: Name, Address and email Address. I also generates a report of all the customer open invoices, and I want to send them individually to their respective customer email addreses.
 
Many ways to accompish this but it will require VBA. If you are comfortable using VBA and want full automation what you would first do is create a module that loops through the recordset of customers that have opened invoices. You would have to check each customer first. If customer has opened invoices then the code needs to proceed to pass that CustomerID value to another function that will modify the query of your invoice report to only pull the open invoices for that customer. At that point you would need to output the report to a PDF file and then use outlook automation and the outlook object library to open a new email window and attach the file.

Let me know if you feel comfortable with this amount of coding and I will send you some examples. If you want a simpler solution let me know what you have in mind and I'll try to give you an example.


http://www.accessmssql.com/
 
If you just want to open the report and print only open invoices for one customer you can add a command button to your Customer screen - use a little VBA to add some code to the OnClick event of the command button as follows:

Docmd.OpenReport "rptInvoices", acViewPreview,,"CustomerID = " & me.CustomerID

This will open the report with the WHERE argument and filter the report by customer.
 
Thanks AccessMSSQL,

Firstly, I am comfortable with VBA.
Secondly, I have never used the emailing feature before.

So to simplify my 1st experience, please guide me as if each customer is getting their report irrespective of whether it is open, thus avoiding the filtering at this stage.

I need the emailing to occur by triggering the event by Click or Dbl click on a button, and the mail is distributed completely and automatically
 
Dear AccesMSSQL,

I decided to go back a bit and learn to send my 1st email. I read the section access on SendOpject for some enlightenment, and I tried the following code but got this error message; Microsoft Office Access can't sent this emal message.

Private Sub Command0_Click()
DoCmd.SendObject acSendTable, "Venues", acFormatXLS, _
" grenee @yahoo.com", , , _
"Current Spreadsheet of Venues", , False
End Sub
 
What email client are you using? Do you have outlook?
 
I'm not sure what the problem would be then. Try testing it with just this:

DoCmd.SendObject acSendTable, "Venues", acFormatXLS,grenee@yahoo.com
leave the other arguments blank and see what happens.
 
Thanks but it give the same problem.

Maybe my problem is with Outlook. I wonder if I have to set it up or just use it as it is.
Can't Yahoo be used instead of Outlook? Maybe nothing is wrong with the statement. Where can I find information on setting up Outlook?
 
Do you have outlook configured?? The SendObject command uses the default email client on the local machine. So you need to configure Outlook. Are you using Outlook Exchange on a network or is this a stand alone computer?
 

Users who are viewing this thread

Back
Top Bottom