gartsports
MIS
Hi all,
I hope someone can help me...I'm new to Java and I downloaded the JBuilder6 personal edition. I've also created a directory to copy in the source examples from the Deitel book. I created the directory c:\jhtp\com\deitel\ and copied the source in there, because I noticed in the book that it uses packages such as "com.deitel.ch02.*;". If I understand it correctly, the package is just a path to a directory under your working directory, right?
Well, after I copied the examples I was able to go into JBuilder, select add package, and select "com.deitel". Now, I'm able to drill down into the individual chapters, exercises, to the source code.
Then I went into the project properties and tried to setup the paths for the project. I set them up as follows:
Source path: c:/jhtp
Test path: c:/jhtp/test
Output path: C:/jhtp/classes
Working directory: C:/jhtp
Required libraries: <none>
Then I added the main class I wanted to try and run:
com.deitel.ch02.Fig02_01.Welcome1
The classpath is as follows:
SET CLASSPATH= .;C:\jdk1.3\bin;c:\jhtp;c:\jhtp\com
When I tried to run it I got the following error message:
java.lang.NoClassDefFoundError: com/deitel/ch02/Fig02_01/Welcome1
Exception in thread "main"
I sure hope that someone can help me figure out what I'm doing wrong. I want to setup 8 PC's so that a bunch of us can work through the book together. Thank you in advance for any assistance!
Chris
I hope someone can help me...I'm new to Java and I downloaded the JBuilder6 personal edition. I've also created a directory to copy in the source examples from the Deitel book. I created the directory c:\jhtp\com\deitel\ and copied the source in there, because I noticed in the book that it uses packages such as "com.deitel.ch02.*;". If I understand it correctly, the package is just a path to a directory under your working directory, right?
Well, after I copied the examples I was able to go into JBuilder, select add package, and select "com.deitel". Now, I'm able to drill down into the individual chapters, exercises, to the source code.
Then I went into the project properties and tried to setup the paths for the project. I set them up as follows:
Source path: c:/jhtp
Test path: c:/jhtp/test
Output path: C:/jhtp/classes
Working directory: C:/jhtp
Required libraries: <none>
Then I added the main class I wanted to try and run:
com.deitel.ch02.Fig02_01.Welcome1
The classpath is as follows:
SET CLASSPATH= .;C:\jdk1.3\bin;c:\jhtp;c:\jhtp\com
When I tried to run it I got the following error message:
java.lang.NoClassDefFoundError: com/deitel/ch02/Fig02_01/Welcome1
Exception in thread "main"
I sure hope that someone can help me figure out what I'm doing wrong. I want to setup 8 PC's so that a bunch of us can work through the book together. Thank you in advance for any assistance!
Chris