Hi,
I would like to ask for help in the following topic. I made this code called in IIS Web Service in order to create pdf file from office documents (Excel, Word, etc.):
Dim oSM, oDesk, oDoc As Object 'OOo objects
Dim OpenParam(1) As Object 'Parameters to open the doc
Dim SaveParam(1) As Object 'Parameters to save the doc
oSM = CreateObject("com.sun.star.ServiceManager")
oDesk = oSM.createInstance("com.sun.star.frame.Desktop")
OpenParam(0) = MakePropertyValue("Hidden", True) ' Open the file hidden
oDoc = oDesk.loadComponentFromURL("file:///" + docFile.Replace("\", "/").Replace("""", ""), "_blank", 0, OpenParam)
SaveParam(0) = MakePropertyValue("FilterName", "writer_pdf_Export")
Call oDoc.storeToURL("file:///" + pdfFile.Replace("\", "/").Replace("""", ""), SaveParam)
oDoc.Close(True)
oDesk = Nothing
oSM = Nothing
The program works perfectly on the developer computer. I have put it on a server, but it wouldn’t work there and it gave me the following error message: Cannot Create ActiveX component. The task is visible in the Task Manager: OpenOffice starts but nothing happens, and in a short time I get the error message.
The server is a Windows 2012 server. I have already set the IIS Application Tools for Administrator rights.
I have also set the rights and identities of Component Services OpenOffice ServiceManagger for Administrator rights. I have set the rights on the File level, too.
I have tried all the solutions I found in Forums, but none of them works.
Please, help me if you can!
Thank you in advance!