First of all, you don't want /QIBM/UserData/Java400/ext in your
CLASSPATH. That directory is for "java extensions" that are always
loaded in all Java invocations. So stuff there is ALWAYS loaded, no
matter what the application is, and is completely separate from the
The reason you don't want to use that directory for everything, even
though it seems simple, is it can cause version conflicts. Your whole
system uses /QIBM/USerData/JAva400/ext, so if one piece of software
needs one version of something, and another piece needs another version
of something, you'd be in trouble if it's in "ext". Not to mention that
loading unnecessary code with every Java program is inefficient.
As for the CLASSPATH itself -- remember it's a list of places to look
for Java classes. Just as a library list is a list of places to look
for programs (et al). Each thing in the classpath is a "container"
(much like a library is a container for programs).
a JAR file is a ZIP file containing many Java "CLASS" objects. So it is
a container -- just like a library would be.
You can also put CLASS files directly in an IFS directory and reference it.
But you can't just reference a directory that contains JAR files.. you
have to list the files themselves, because JARs are containers. They're
not the CLASS files themselves.
On 2/6/2013 11:36 AM, tim.dclinc@xxxxxxxxx wrote:
im using Scott's POI to write excel documents. I placed the jar files in
the ifs "java" folder. I modified the classpath as follows:
when i try executing my code, i get a class not found error. I modified
the classpath as follows again:
and now it works.
Im not sure why i have to specify the jar file in the classpath. Why
doesnt it work just specifying the folder the jars are contained in.