Anyone successfully used PDFCreator COM Object with PHP in Windows Server?

 I can use with no problems in Windows 7, but not in Windows Server.

I have to configure COM Settings ? My SYSTEM user already has fullrights.

I can save settings and save them to PDFOptions.ini file with no problem, but freeze when send cPrintfile command.

Any ideais ?

1 Like



do you have the latest version of PDFCreator installed (1.4.0)?





 Yes. Version 1.4.0.

If I try, for exemple, send a file to print 3 times, the pdfcreator appear on tasklist but not nothing happens and when I open the file in Word and send to print then pdfcreator prints 4 documents. 

Did you use server mode during setup?





 Tried both modes.

Now is in normal mode, what I think is the correct one for my setup. Or not ?



could you post your code here? What kinfd of documents are you trying to print? Normal setup should usually be the right choice.





I'm trying print a docx file. The PDFOptions.ini file is created and PDF Creator is launched, but do nothing. I think that can be some security settings or some issue with apache, the user SYSTEM has fullrights to launch COM.

I'm writing a VB version to test.

Code below:

$PDFCreator = New COM("PDFCreator.clsPDFCreator") or die("Couldn\\' start the COM-object");
$options = $PDFCreator->cOptions;
$options->UseAutosave = 1;
$options->UseAutosaveDirectory = 1;
$options->AutosaveFormat = 0;
$options->AutosaveDirectory = 'E:\\\\Sistema\\\\tmp';
$options->AutosaveFilename = 'oi';
$PDFCreator->cOptions = $options;
$www = "E:\\\\Sistema\\\\tmp\\\\PDFOptions.ini";
$PDFCreator->cPrinterStop = false;


VS2010 (Visual Basic) and PDFCreator 1.4.0 works great in Windows Server, must be something with php or apache, still looking for it. 


 I can print PDF Creator teste file, printer teste file, can convert .ini to pdf, txt to pdf, but When try converting any office file to pdf, the correct program opens (winword, excel) but still freeze.

Any ideas ?

 I had the advanced logging enabled. When printing a *.txt to *.pdf it works fine with the following log:

`[27.05.2012 16:34:33]Modul-PdfStartDocPort=Start`

`[27.05.2012 16:34:33]PrinterName=PDFCreator`

`[27.05.2012 16:34:33]JobId=27`

`[27.05.2012 16:34:33]ComputerName=\\\\SYM-SERVER2`

`[27.05.2012 16:34:33]UserName=Administrador`

`[27.05.2012 16:34:33]SessionId=2`

`[27.05.2012 16:34:33]WinStation=RDP-Tcp#0`

`[27.05.2012 16:34:33]Modul-GetUserTmp=Start`

`[27.05.2012 16:34:33]Modul-GetUserTmp=End: True`

`[27.05.2012 16:34:33]TmpPath=C:\\Users\\ADMINI~1\\AppData\\Local\\Temp\\2\\PdfCreator\\Spool`

`[27.05.2012 16:34:33]PostscriptFile=C:\\Users\\ADMINI~1\\AppData\\Local\\Temp\\2\\PdfCreator\\Spool\\`

`[27.05.2012 16:34:33]DocName=oi.txt - Bloco de notas`

`[27.05.2012 16:34:33]Modul-PdfStartDocPort=End: True`

`[27.05.2012 16:34:33]Modul-StartPdfCreator=Start`

`[27.05.2012 16:34:33]EnvironmentSize:=1443`

`[27.05.2012 16:34:33]CommandLine= /PPDFCREATORPRINTER /PIFC:\\Users\\ADMINI~1\\AppData\\Local\\Temp\\2\\PdfCreator\\Spool\\F61D97A77A0A44D7B24A816922EB9EA9.inf`

`[27.05.2012 16:34:33]Command=C:\\Program Files (x86)\\PDFCreator\\PDFCreator.exe`

`[27.05.2012 16:34:33]Modul-StartPdfCreator=End: True`

 When trying print *.doc to *.pdf (or another office file) PDFCreator is started Office Application is started and both still open forever and no pdf is created and no log also.

I dont have any more ideias for test, if anyone has a clue, please tell me!


To me it looks like a security problem. You are using Apache/php to do the conversion, right? Most likely this leads to a security restriction, as calling Word from the System account can lead to problems. Maybe it can help that you install PDFCreator in server mode. You will have to make sure that an instance of PDFCreator is running under the account of an administrator user.

Then calls to the PDFCreator COM classes will end up in a proper account. So maybe this works, but I can't tell for sure.

kind regards,

 Hi Philip,


I already launch Apache under Administrador account, but will try the sever mode.



 Hi Philip,


I already launch Apache under Administrador account, but will try the sever mode.



Hi, did you solve this ?
I got same problem creating report to PDF
If use in desktop environments, it is OK
But do not in Apache web server application