Report Print Into PDF File Automated By VBA

F

Fuad

Dear friends,

I want to automate the report print into file by the predefining the file
name in the VBA code. I've got CutePDF printer in my pc and I select it as a
defaul printer, then use ...DoCmd.OpenReport "Report", acViewNormal...
method to save the report as a PDF file. It works fine, but I would like to
automate the following issues:
1. Avoid resetting a default printer every time: when the control button is
pressed the CutePDF printer is selected even though a hard copy printer is
set as a default;
2. The unique file name is predefined in the code and copied in the "File
name" field of the showing up "Save As" dialog box, and you just locate the
file in the folder and save it.
May the folder location also be defined in the code to skip the "Save As"
window poping up at all?
Could you please help me with these issues or recommend other best practices
used for that case.

Thanks.
 
A

Albert D. Kallal

use Lebans solution here:

http://www.lebans.com/reporttopdf.htm

Advantage of above:

it is free
it does not requite a printer driver install
id doest not requite you to switch printers
it allows youth to specify the output name via code.

The free Cutepdf does not allow you specify the pdf output in code.....
 
G

GK

Hi, I am also use this utility. is a way I can pass a filter criteria because
my report use a query that requires dynamic critera at run time.

thanks.
 

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