OpenOffice.org Forum at OOoForum.orgThe OpenOffice.org Forum
 
 [Home]   [FAQ]   [Search]   [Memberlist]   [Usergroups]   [Register
 [Profile]   [Log in to check your private messages]   [Log in

Problem when load openoffice with tomcat as service

 
Post new topic   Reply to topic    OOoForum.org Forum Index -> Setup and Troubleshooting
View previous topic :: View next topic  
Author Message
jairorivero
Newbie
Newbie


Joined: 26 Oct 2007
Posts: 1

PostPosted: Fri Oct 26, 2007 7:00 am    Post subject: Problem when load openoffice with tomcat as service Reply with quote

Hello, I am new in this forun, i am not write english perfect, sorry.

I have one problem

I have tomcat y openoffice, when start tomcat as DOS console, no problem. when start openoffice as window service, it is stop when new instance bootstrap(), this is method what open document.

public XComponent openFile(String sourceFile) throws Exception {
// get the remote office component context
System.out.println("Voy a conectarme a office ...");
com.sun.star.uno.XComponentContext xContext = com.sun.star.comp.helper.Bootstrap.bootstrap(); // this point, no application move, is loop ??????
System.out.println("Connected to a running office ...");

// get the remote office service manager
com.sun.star.lang.XMultiComponentFactory xMCF = xContext.getServiceManager();
Object oDesktop = xMCF.createInstanceWithContext("com.sun.star.frame.Desktop", xContext);

xCompLoader = (com.sun.star.frame.XComponentLoader) UnoRuntime.queryInterface(com.sun.star.frame.XComponentLoader.class, oDesktop);

//System.out.println(sourceFile);
//sourceFile = sourceFile.replaceAll("\\\\","\\");
System.out.println(sourceFile);
System.out.println(toUrlFile(sourceFile));
return xCompLoader.loadComponentFromURL(toUrlFile(sourceFile), "_blank", 0, MakePropertyValue(new String[]{"Hidden"},new Object[]{new Boolean(true)}));
}


i write de classpath.

this is line in command line.

tomcat5 //TS//Tomcat5 --Classpath="%JAVA_HOME%\lib\tools.jar";"%CATALINA_HOME%\bin\bootstrap.jar";"C:\Program Files\OpenOffice.org 2.3\program\classes\jurt.jar";"C:\Program Files\OpenOffice.org 2.3\program\classes\juh.jar";"C:\Program Files\OpenOffice.org 2.3\program\classes\unoil.jar";"C:\Program Files\OpenOffice.org 2.3\program\classes\ridl.jar";"C:\Program Files\OpenOffice.org 2.3\program\soffice.exe"

run perfect, but window service, loop loop loop loop loop

Help me please
Thanks avance
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    OOoForum.org Forum Index -> Setup and Troubleshooting All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group