|Pathologically Eclectic Rubbish Lister|
Converting RTF documents to PDF formatby mlh2003 (Scribe)
|on Feb 14, 2005 at 12:35 UTC||Need Help??|
mlh2003 has asked for the wisdom of the Perl Monks concerning the following question:
Hello exalted monks,
I have a problem that I cannot seem to find within the monastery nor 'out there in Google-land'.
I have been looking at converting Word documents to PDF format using perl, and soon realised that I hit my programming and time limits and thought of converting the Word .doc to .rtf first. Then I could use a couple of modules available from CPAN. One to convert from rtf to HTML (RTF::HTML::Converter) and then take the HTML file and put it through a HTML to PDF conversion module (PDF::FromHTML). Kind of like putting a cow through 2 black boxes and getting barbeque steak at the end...
The only problem is that the first black box (RTF::HTML::Converter) seems to hang the server and returns nothing unless the .rtf file is very simple. My code that attempts the conversion follows, which uses the modules in a way that closely resembles the usage in their respective documents:
Have any monks here experienced this behaviour with that module, or even walked a different path to start with RTF and arrive at HTML (or better yet, PDF)?
Any help would be greatly appreciated.