Destroy COM resource
Posted: Wed Jun 06, 2007 3:08 pm
feyd | Please use
Nothing after this last line executes, but it does create a new pdf file called "FirstPDF.pdf" just fine. Any idea how to wrestle control back from $objPDF? I've tried unset(), but I don't believe it's being executed.
TIA
feyd | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]
I purchased a program that converts html files to pdf on a Win2000 server. It works great, but the page hangs. I think the object isn't relinquishing control. The code is:Code: Select all
$filename = "C:\\inetpub\wwwroot\TestSite\test.html;
$objPDF = new COM("HTMLConverter.HTMLConverterX");
$strPDFFile = "C:\\inetpub\wwwroot\TestSite\FirstPDF.pdf";
$strHTMLFile=$filename;
$stroptions = "-cpdf";
$objPDF->Convert($strHTMLFile,$strPDFFile,$stroptions);TIA
feyd | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]