× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.


  • Subject: Re: Why CLASSPATH behave so strange?
  • From: pytel@xxxxxxxxxx
  • Date: Fri, 26 Mar 1999 11:36:49 -0600

I tried this on V4R3 system - it works exactly as I described in my
previous note.
When in shell session, enter   echo $CLASSPATH   to check what is the value
of CLASSPATH variable.
Make sure that you use correct case - Java and everything originating from
UNIX are case sensitive.
Another thing - just in case - did you compile your Java program ?
You first create Hello.java with plain text Java program, then call  javac
Hello.java  to generate Hello.class and then run the program by  java Hello
. (I mention this because I made exactly this mistake at my first shot at
Java.)

Best regards
    Alexey Pytel



Ioachim@aol.com on 03/26/99 10:00:32 AM

Please respond to JAVA400-L@midrange.com

To:   JAVA400-L@midrange.com
cc:    (bcc: Alexei Pytel/Rochester/IBM)
Subject:  Re: Why CLASSPATH behave so strange?





Still,

Still, I have problems with understanding this CLASSPATH. You said '.' is a
default for CLASSPATH. But it says "UNABLE TO FIND CLASS Hello", if I do
not
create CLASSPATH with the value '.'

Furthermore, if this CLASSPATH is not created, then no matter what I do, I
get
"UNABLE TO FIND CLASS Hello". And here are my experiments:

I close the session and logon again, because I cannot otherwise delete this
CLASSPATH var - the WRKENVVAR offers you the capabilities only to create or
change, NOT TO DELETE, an environmental variable. (Why???)
OK, I logon and, when I do WRKENVVAR, I do not find this CLASSPATH. Then I
do
one of
1. CD '/TEMP' (It is in /temp that I have the Hello.class), qsh cmd('java
Hello')
2. STRQSH session, do CD '/TEMP', then java Hello
3. STRQSH, do /TEMP/Hello
All of these bring to the same  "UNABLE TO FIND CLASS..."  Especially
strange
is the case 3. Why it does not find, even when you indicate the full path!?

There was an answer  to my message from somebody else from IBM, but I only
opened the message, it was marked as read by my AOL and was not downloaded
- I
did not manage to read it. Could you please forward that message too, if
you
happen to answer this message. Thank you very much!

<< This is because STRQSH starts its own job and does not inherit current
 directory setting from your original job. You may prove it by issuing pwd
 command from a prompt after STRQSH.
 You may run Java program by calling STRQSH CMD('java Hello'). In this case
 current directory WILL be inherited.

 BTW, you do not need to bother adding '.' to CLASSPATH. It's there by
 default.

 Environment variables are job attributes and are lost, when job ends.

 Best regards
     Alexey Pytel"
  >>
+---
| This is the Midrange System Mailing List!
| To submit a new message, send your mail to JAVA400-L@midrange.com.
| To subscribe to this list send email to JAVA400-L-SUB@midrange.com.
| To unsubscribe from this list send email to JAVA400-L-UNSUB@midrange.com.
| Questions should be directed to the list owner/operator:
david@midrange.com
+---



+---
| This is the JAVA/400 Mailing List!
| To submit a new message, send your mail to JAVA400-L@midrange.com.
| To subscribe to this list send email to JAVA400-L-SUB@midrange.com.
| To unsubscribe from this list send email to JAVA400-L-UNSUB@midrange.com.
| Questions should be directed to the list owner/operator: david@midrange.com
+---


As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.