printing to file

  • Thread starter Thread starter Clint
  • Start date Start date
C

Clint

I am printing a report with the simple statement
DoCmd.OpenReport "Tracking Sheet". I want to be able to
print this report to a file. Is there a simple way to
execute a report from code and print to file?

Thanks,
Clint
 
Clint:

The answer depends on what type of file you want to output. Access can
natively output a report that is not filtered to either an RTF or Snapshot
file (which is an image of the report) using the built in OutputTo Action or
OutputTo method. To output a simple report to a spreadsheet or text file
you can also specify that with OutputTo; but note that those file formats
don't generally get converted well with complex reports.

If you want a printer file (e.g. a prn or postscript file,) then no, there's
no native way to do that in Access. However, if that's what you want then
take a look at our Print To File Manager for Access (its on our web.)

Last if you are looking for a file format like a PDF file, then again no,
Access doesn't support it natively. There are other tools you can use to do
that however, including our PDF and Mail Library for Access.
 
It's been a while, but I thought I would post my reply.
It doesn't matter the file type. I am testing a report
and instead of printing it over and over again, I want
some sort of file to refer to. Opening it up in print
preview will not due. Can you pass on the code to print
to a spreadsheet or text file? This will save me lots of
frustration.

Thanks,
Clint
 
Back
Top