Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / April 2006

Tip: Looking for answers? Try searching our database.

rmi classpath

Thread view: 
James.li - 04 Apr 2006 02:06 GMT
I have a question when I write RMI program .

file direction as follow:
D:\project\
D:\project\build\
D:\project\build\classes\
D:\project\build\classes\report\
D:\project\build\classes\report\ReportAssist.class
D:\project\build\classes\report\ReportAssistImpl.class
D:\project\build\classes\report\ReportAssistServer.class
D:\project\build\classes\report\ReportAssistClient.class
D:\project\build\classes\report\ReportAssistImpl_Stub.class

D:\project\lib\
D:\project\lib\jdom.jar
D:\project\lib\sqljdbc.jar

D:\project\config.xml

#rmiregistry 2001
cd D:\project\
set CLASSPATH=./lib/;./build/classes/
rmiregistry 2001   --has success

#start server
cd D:\project\
java -Djava.rmi.server.codebase=file:D:\project\lib\ -classpath
./build/classes/ report.ReportAssistServer  --has success

#start client
cd D:\project\
java -Djava.rmi.server.codebase=file:D:\project\lib\ -classpath
./build/classes/ report.ReportAssistClient

--exception
java.lang.NoClassDefFoundError: org/jdom/JDOMException

The server side has printed information when start client .

How do I set the classpath ?
Paul Hamaker - 04 Apr 2006 07:50 GMT
jars have to be named in a cp :
set CLASSPATH=./lib/jdom.jar;./lib/sqljdbc.jar;...etc
--------------------
Paul Hamaker, SEMM, teaching ICT since 1987
http://javalessons.com
James.li - 10 Apr 2006 02:36 GMT
yeah ..you are right ...thanks you .


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.