SendObject not working first record.
I am very new to access, I have a form that on Load runs the GoToRecord macro and selects new which should mean im ready to enter a record, at the end is a button to email that record to whichever department needs it. my problem is if you open the form and fill out the data, the email attachment is always blank just with the field names, if you go back into the form and actually click the new record button and fill it out it all works fine
Thank you for taking the time to report an issue.
What's wrong... Please write below.
Where do I put the following syntax and how do I link it to a command button on my form?
DoCmd.SendObject [type][, name][, format][, to][, cc][, bcc][, subject][, body][, edit][, template_file]
I've been reading up on it for the past 90 mins to no avail
DoCmd.SendObject acReport, stDocName, acFormatPDF, COUemail, , , subject1, "Please see attached a new Carriage Forward Request"
The email works fine but when it opens it automatically gives the users email address as the 'From', I want to put in a different one.
This works in MailModule.SendEmail, but can I get it work in SendObject?
the email is sent using the SendObject command
Its seems acExportQualityScreen is the default on SendObject though. Is there any way to change this? I see there is this option when you do a OutputTo command, but not on SendObject command.
In the SendObject macro, I have typed the following in the Template File argument:
"C:\Documents and Settings\cimbrie\AA Database\Invoice test Template_files".
I have tested the link by clicking on it in Word and it takes me to the AA Database folder and selects the file. I interpret that to mean the path is right.
The SendObject does not open the template. It just opens a new email.
DoCmd.SendObject acSendReport, "rpt_Certificate", acFormatPDF, "firstname.lastname@example.org", , , Subject, Body, Yes, ""
Something similar to this:
Private Sub txtemail_Click()
DoCmd.SendObject acSendNoObject, , , emailtxt, , True