I seem to have trouble using the CLASSPATH in my environment. I'm running
Red Hat 5.2, JDK 1.1.6.

I put the following into ~./bashrc:
        CLASSPATH=.  (also tried CLASSPATH=.:$CLASSPATH)
        export CLASSPATH
Now when I run $ printenv I get:
        CLASSPATH=.  (or CLASSPATH=.:)

I assumed this would let me run a JavaApp.class file anywhere:
        $ java JavaApp
But such is not the case. I can only run JavaApp if in the directory
        $ java ./JavaApp
If I try to supply a path
        $ java /path/JavaApp
I get "invalid class name." If I run from the JavaApp directory:
        $ java JavaApp
I get "Cannot find class JavaApp."

Haines Brown

Reply via email to