Hi Jennifer,
Jennifer Palm-Ensign wrote:
Hi Stephan,
Thanks for your response.
What I'm doing is building a little application in my Windows
environment where I do
have OpenOffice 2.0 installed as well as the Open Office jdk. Am using
NetBeans for this.
I do have the jars - juh.jar, jurt.jar, ridl.jar, unoil.jar, plus
jut.jar and officebean.jar in the lib.
So, my little app runs and builds fine on my Win machine.
After sending it to the UNIX test server it needs to eventually run on,
that is where I get the errors I sent you. That server only provides
staroffice from NFS.
First problem: I cannot get NetBeans to put any manually added classpath
info in the
build manifiest file. It seems NetBeans has it's own agenda for Open
Office applications
and puts into the build manifest file the following main class:
Main-Class: com.sun.star.lib.loader.Loader
And does not list the files in the lib folder as Netbeans by default
/normally/ does.
independent of the fact that the ant scripts of our specialized NetBeans
projects need to be improved, it shouldn't be necessary that you insert
the UNO jars there.
The NetBeans project wizard creates a project which is prepared to use
the simple UNO bootstrap mechanism. The mechanism prepares an own
classloader having the necessary UNO jars already included. This client
applications work on all supported platforms where a
OpenOffice.org/StarOffice program is installed normally. In your case
using a office over nfs it probably won't work. You can try to insert a
link on your test server in /usr/bin/soffice -> to your real
<nfs_path</openoffice.org2.0/program/soffice
Juergen
I cannot add additional classpath information to the editable manifest -
it ignore this as well.
I would ask you more, but this is enough for now :-)
Thanks,
Jennifer
Stephan Bergmann wrote:
Jennifer Palm-Ensign wrote:
Hello,
Pardon me if this not the right list for this question. But I'll give
this a try:
I am developing an application on OpenOffice on a Win system, am
testing to see
if the .jar can connect to star office on Solaris on a remote test
system that mounts staroffice
from NFS.
I get the below pasted error and would like to know:
1) Is it okay to be connecting to a mounted version like this
(presumably these NFS versions are for people to use as clients on
their workstations)
2) If so, can someone point me to how to properly point my little
application to a remote
instance of soffice, like how to get the classpath right in this case?
3) Should I just install OpenOffice on the test/development server?
command: java -classpath /usr/dist/share/staroffice,v8.3 -jar
MyOfficeUNOClientApp.jar
Your application will need a bunch of jars from the Java UNO Runtime
(juh.jar, jurt.jar, ridl.jar) and one OOo-specific jar (unoil.jar).
All of them are available in an OOo installation in the
program/classes sub-directory. (So, one fix for your problem would be
to extend the above -classpath to list those jars explicitly; you
mention your client is Windows, but /usr/dist/share... is probably not
a working file path on Windows, even for an NFS mount---you need to
adapt that to Windows syntax.)
However, some of the jars mentioned above use native code (which they
automatically find next to themselves in the program directory of the
OOo installation). If your application would happen to use any such
functionality that depends on native code, it would fail, as the jars
from the (Solaris) OOo installation would find Solaris native code
that does not work on Windows.
So, what you need on the client side is:
- The (Windows-specific version of the) UNO Runtime Environment (URE),
which contains the necessary juh.jar, jurt.jar, and ridl.jar. It is
available at <http://udk.openoffice.org/#ure>.
- Plus the OOo-specific unoil.jar, which you can take from the Solaris
OOo installation (it does not use native code as described above).
Either copy it somewhere on your Windows machine or reference it
directly on the -classpath using appropriate Windows syntax.
Feel free to come back here with more questions,
-Stephan
com.sun.star.lib.loader.Loader::getCustomLoader: no UNO installation
found!
Exception in thread "main" java.lang.NoClassDefFoundError:
com/sun/star/lang/XComponent
at java.lang.Class.getDeclaredMethods0(Native Method)
at java.lang.Class.privateGetDeclaredMethods(Class.java:1655)
at java.lang.Class.getMethod0(Class.java:1901)
at java.lang.Class.getMethod(Class.java:984)
at com.sun.star.lib.loader.Loader.main(Loader.java:142)
Thank you,
Jennifer Palm-Ensign
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]