I’ve found some code a colleague wrote a couple of years ago.
Basically it looks through a recordset, opening the report for a single record at at time and uses an attribute of the record to set part of the report caption.
For each record, the report is opened in preview mode, its caption is set to be a path and file name (complete with file extension ‘.pdf’) and then it is printed using DoCmd.Printout. The report is then closed and the loop repeats.
By using Jaws pdf as the default printer, correctly named pdfs are then created in the correct folders without any user intervention. This handy quirk didn’t work with any other pdf printers/writers.
I though this would be useful for something I’m doing now, however, Access is behaving a little oddly.
The report is being sent to a printer I don’t have on my system, even though its print settings are set to ‘use default printer’
The printer appears to be one in a different office (where my colleague who is using the db works).
Any ideas?