Exporting a Completed Form to PDF VBA

brian7268

Registered User.
Local time
Today, 15:35
Joined
Mar 19, 2013
Messages
20
I have a form that a user fills out and the record is not uploaded to the database until the user hits the submit button. In other words, if the user closes the form without saving, the record is not inserted.

My end goal is to have the user click the button and have 3 things happen:
1) Record inserted into the database
2) A PDF of the record is saved to a per-identified directory
3) An outlook new message window opens with recipients pre-entered and the newly created PDF included as an attachment.

I can achieve steps 1 and 2 no problem. However, the way I get the PDF is by having the VBA simply print and the user selects the Adobe PDF. This does not let the VBA dictate the directory (or file name) and then makes me completely stumped for step 3.

Any help would be GREATLY, GREATLY appreciated as I am at a complete dead end.

Thanks!
 
Why not create a Report that replicates the feel of your form and send that direct to PDF (assuming you are using '07 or latter)?
 
Thanks for the reply!

2 Questions:
1) Can you easily create a report to look exactly like the form without starting from scratch?

2) More of a general question - I am using Access 2010, but saving to MDB file format so it is compatible with software that will be linking to it. Does it go by the software release you are using or the file extension? (in regards to your question if I am using 2007)
 
Can you easily create a report to look exactly like the form without starting from scratch?
Well, not completely easily but you can take a form and select SAVE AS (if in 2007, or SAVE OBJECT AS in 2010) and save it as a report. You will need to fix a bunch of things but it will start you off.
 

Users who are viewing this thread

Back
Top Bottom