Article View: borland.public.jbuilder.java.language
Article #14744Re: Deployment Problems
From: Rich Wilkman
Date: Thu, 05 Aug 1999 00:00
Date: Thu, 05 Aug 1999 00:00
73 lines
3190 bytes
3190 bytes
Bill: First: You need the items on the CLASSPATH, not the PATH for Java to find them. Second: Since you are on a PC, the separator is a semi-colon, not a colon. Colon is correct for the *nix world. Third: Using the jre is just like using java.exe to run your program. You don't specify the .class extension, just the fully qualified name of the class you want to run. Fourth: The fully qualified name of your class is important. With the info you provide I would assume that the package name is test. Your command line would look more like: jre -cp .\testjar.jar test.testpgm It may be a little different if you are using JDK 1.1 and JFC, etc. I tend to recommend using the CLASSPATH variable instead of -cp -Rich Bill Bell wrote: > > Is there a step by step guide to deploying a simple app? > > 1. Using JBuilder 3 I created a VERY simple app under myprojects/test - > testpgm.java calls Frame1.java > 2. I compiled and ran the program. > 3. I used the deployment wizard to create a jar file (testjar.jar) > 4. The jar file has all the classes I used to create the simple app. > (I looked at the contents of the jar file and it has everything). > 5. I created a directory c:\test and put the jar file in the directory. > 6. I downloaded the JRE (from SUN) and installed it in c:\jre > 7. I updated my autoexec.bat file to include the path and rebooted. > SET PATH="%PATH%";c:\jre\bin;c:\jre\lib; > (There is nothing else in the path) > 8. I opened a dos window and cd to the test directory c:\test > > c:\test>jre -help > > and I get jre help - so far so good. Then I tried several ways to > execute > the app. > > c:\test>jre -cp .:testjar.jar testpgm.class > c:\test>jre -cp .:testjar.jar testpgm //I thought it may > append .class > c:\test>jre -cp .:testjar.jar test\testpgm.class //Testpgm is in a > directory called test > > In all cases it does not find the class I specified. What am I doing > wrong? > > I also want to figure out how to create an Icon on the desktop to call > the app. > > Any help is very much appreciated....thanks. > > Regards, Bill Bell -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Rich Wilkman Quality Assurance Manager Borland JBuilder Team If you see something that looks like an opinion up there, it's mine and mine alone. Mail sent to me from the newsgroups won't bounce but will be ignored. If I have time, I'll respond, but you have a better chance if you confine your posts to the newsgroups =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Technical Details
Message-ID:
<37A9F730.C9AA06D9@inprise.com>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailReferences:
<37A92421.6D999898@airmail.net>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f74b3,7ef6072b61e321a0 X-Google-Attributes: gidf74b3,public From: Rich Wilkman <rwilkman@inprise.com> Subject: Re: Deployment Problems Date: 1999/08/05 Message-ID: <37A9F730.C9AA06D9@inprise.com> X-Deja-AN: 509317097 Content-Transfer-Encoding: 7bit References: <37A92421.6D999898@airmail.net> X-Accept-Language: en Content-Type: text/plain; charset=us-ascii Organization: Another Netscape Collabra Server User Mime-Version: 1.0 Newsgroups: borland.public.jbuilder.java.language