Result!
Yesterday I searched for a long-standing problem to do with sending faxes automatically using a VB (Visual Basic) program.
In a nutshell, I was using some software that had been written eons ago which printed documents to the Printer object (Printer.Print / Printer.EndDoc, that sort of thing). The trick was that if you "Set" the Printer object to an installed FAX printer (in the Printers Folder) then you could simply fax it off around the world.
The problem was that no matter what fax software you used you always got prompted for the fax number - which of course is no good if it's an unattended server. So, the now-since-retired people who wrote it came up with the ingenious solution to use VB AppActivate and SendKeys to enter the fax number into the fax number dialogue. This works just fine when it's WinFax; and when you have a telephone line within earshot of the server - which we don't.
The "modern" solution to faxing where I work now is to send an email to "faxnumber@Fax.com". This works just fine from Outlook and Notes when you attach the file that ends up as a fax.
So, how do you create a file using the Printer object which you can then attach to the mail?
If you're with me so far, then you probably really are looking for an answer to this.
And it's this - use the PDF Printer from these guys: Bullzip.com.
Here's the real genius of this product. You can set it to NOT throw up a "Save As" dialogue and you can write the "Save As" filename to its .INI file instead.
In a nutshell, I was using some software that had been written eons ago which printed documents to the Printer object (Printer.Print / Printer.EndDoc, that sort of thing). The trick was that if you "Set" the Printer object to an installed FAX printer (in the Printers Folder) then you could simply fax it off around the world.
The problem was that no matter what fax software you used you always got prompted for the fax number - which of course is no good if it's an unattended server. So, the now-since-retired people who wrote it came up with the ingenious solution to use VB AppActivate and SendKeys to enter the fax number into the fax number dialogue. This works just fine when it's WinFax; and when you have a telephone line within earshot of the server - which we don't.
The "modern" solution to faxing where I work now is to send an email to "faxnumber
So, how do you create a file using the Printer object which you can then attach to the mail?
If you're with me so far, then you probably really are looking for an answer to this.
And it's this - use the PDF Printer from these guys: Bullzip.com.
Here's the real genius of this product. You can set it to NOT throw up a "Save As" dialogue and you can write the "Save As" filename to its .INI file instead.
- Set Printer = objPrinter
- WritePrivateProfileString "PDF Printer", "Output", msFaxSaveFilename, Environ$("APPDATA") & "\PDF Writer\Bullzip PDF Printer\Settings.ini"
- Printer.Print "stuff to print"
- Printer.EndDoc
Comments