Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Free PDF converter for VBScript?

Status
Not open for further replies.

rss0213

Programmer
Jul 12, 2007
58
US
I'm new to VBScript, but I've written and modified a few scripts...

I need to read a report file (ASCII format), and generate multiple PDF files from certain pages in the report. I can handle the logic to parse the report file into multiple documents, but I'm trying to find a free tool to convert those documents to PDF files. This script can be installed to run on Windows Server 2003 or XP machine, which ever is required.
 
isnt there some sort of PDFPrinter? its installed and looks like a printer, when you print to it it spits out a pdf?
 
No, I do not use MS Office 2007.

I'm using a "sendmail" app to send the faxes via email with the PDF attached (I used veryPDF, aka text2pdf), but the document is printing on the fax machine as "garbage" data. I suppose this is because of the fax service I'm using (Lightning Fax) not properly sending the attachment for the fax? But the MIME encoding appears to be correct (Content-Type: application/PDF). Can someone please explain this?


Thanks!
Scott
 
Thanks. I'm using txt2pdf.exe. It's freeware I downloaded from veryPDF.com. It provides command line functionality, which is what I need. I also use PrimoPDF, but I use it to print documents to PDF "manually". txt2pdf.exe will allow me to create batch scripts "on the fly" to generate the PDF documents I need.

Thanks again for everyone's help.

Thanks!
Scott
 
Scott, I haven't seen Lightning fax since my days at Sprint. But I am almost certain that have an API that exposes some functionality that can be used. We used the API for some document processing in the call centers way back when... Before all the mergers. (WorldComm, ect)

Later

Thanks

John Fuhrman
faq329-6766
faq329-7301
thread329-1334328
thread329-1424438
 
That's right, John, and that's what I've decided to use (LF the API). I'm still going to create my PDF files with txt2pdf, then my VBscript will generate each "command file" for LF to send the faxes. The command file will contain instructions to send the PDF as the fax.

Thanks!
Scott
 
So, have you got it figured out or is there something we can help you with?

If there is something you need assistance/guidence on post some code and comments on what you have attempted so far and what you need to help with.



Thanks

John Fuhrman
faq329-6766
faq329-7301
thread329-1334328
thread329-1424438
 
No, I'm good. (Sorry for not making that clear.) I've decided to do everything using VBA instead of VBscript because my users have an Access DB of customer info that contains the fax number. This is what I'll be doing:

1. Export reports from report repository (we use Mobius on the mainframe, which has a "fat client" app called Document Direct for PC-based report retrieval). The VBA code will run a batch file to do this (batch file opens Doc Direct link with start-up script as a parm to execute the .msl export script).
2. Read reports file export to separate each customer's report to a separate file named COMPANYID.RPT (e.g. 1234567890.RPT).
3. Use txt2pdf to generate .RPT file to .PDF. The txt2pdf will also be run from a batch file, and it will have a parm to reduce the font size to 8, set the orientation to landscape, and rotate the document 90 degrees (necessary for rendering the PDF image to the fax recipient properly; otherwise the text in the report "wraps").
4. Build command files for LF to send the faxes. Each command file will be named COMPANYID.TXT and placed in the "convert" directory on the LF server. LF continuously polls this directory and processes any ASCII file as a command file. Again, fax numbers are already stored in the Access DB.

I think that's "all there is to it"... :)


Thanks!
Scott
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top