Save as PDF

Mac OS X, any version.
Problem: Programmatically save the current file as PDF from an AppleScript-supporting application, in this case Excel v. X. (Excel’s Visual Basic for Applications does not support this function, but could call an AppleScript if it could provide the solution. Excel also has no terminology to do this under AS control.)
The Print dialog’s Custom setting can save to PDF, and Excel programmatically uses the Custom setting when it was the last setting used in the Print dialog. But its selection cannot be guaranteed. Neither does AppleScript seem to be able to do this.
It is also extremely difficult to extract the PostScript file from the queue folders. Although Print Center’s scriptability was heavily promoted, it can’t even change the default printer. Therefore, to find the PostScript file for a particular just-printed job, a script would have to hunt multiple folders for the file with the latest modification date.
Any ideas for a solution other than simulating a live user with QuicKeys X?
Thanks.

: Mac OS X, any version.
: Problem: Programmatically save the current file as PDF from an
: AppleScript-supporting application, in this case Excel v. X. (Excel’s
: Visual Basic for Applications does not support this function, but could
: call an AppleScript if it could provide the solution. Excel also has no
: terminology to do this under AS control.)
: The Print dialog’s Custom setting can save to PDF, and Excel programmatically
: uses the Custom setting when it was the last setting used in the Print
: dialog. But its selection cannot be guaranteed. Neither does AppleScript
: seem to be able to do this.
: It is also extremely difficult to extract the PostScript file from the queue
: folders. Although Print Center’s scriptability was heavily promoted, it
: can’t even change the default printer. Therefore, to find the PostScript
: file for a particular just-printed job, a script would have to hunt
: multiple folders for the file with the latest modification date.
: Any ideas for a solution other than simulating a live user with QuicKeys X?
: Thanks.
I had a similar problem with trying to activate printers under OS X and had to reveret to a couple of shareware extensions and some work arounds. To print from applications that hat not PDF support under AS I used PDF printer.
Then to select printers I downloaded a printer selection extension under OS9 which supported AS then saved the code as applications. In my OSX script i then called these applications to switch printers.
I know its a bit mickey mouse but it works.
Steve