× 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.



Ok, I rename the file HELLO.JAVA to hello.java, then typed javac hello.java 
in STRQSH.

This time the following error occured.

 javac hello.java
 error: cannot read: hello.java
 1 error
 £


Any idea please ?

Further, what java tool is best for pc for testing, compiling and then 
transfer to AS/400.

Best Regards,

Luqman
b



"Joe Pluta" <joepluta@xxxxxxxxxxxxxxxxx> 
wrote in message news:004101c5abdc$8c2559a0$1901010a@xxxxxxxxx
> Well, you're doing Java like you would do RPG.  Unfortunately, Java is a
> completely different animal from RPG, so just about everything you're
> doing is wrong <grin>.
>
> Among the issues:
>
> 1. Java is case sensitive, OS/400 is not.  In fact, the commands you've
> shown below should not have worked at all, and you should have seen the
> following:
>
> qsh: 001-0019 Error found searching for command JAVAC.  No such path or
> directory.
>
> The only way uppercase JAVAC would have worked (at least on my machine)
> is if there were a symbolic link created that pointed JAVAC to javac.
>
> 2. Anyway, if you type in "javac HELLO.JAVA", you will get the error you
> described.  Why?  Because it doesn't recognize ".JAVA" as a valid
> extension, and this is again due to case.  You need HELLO.JAVA to
> actually be HELLO.java, and then javac will recognize it.
>
> 3. If you get past this, you will STILL have a problem, because the name
> of the file (excluding the .java extension) must match the class name of
> the class being compiled.  In this case, your class name is HelloWorld,
> so the name of the file (case sensitive, remember) must be
> HelloWorld.java.
>
>
> Whew!  Welcome to Java, my friend!  I suggest a book such as Java for
> RPG Programmers to get some more information about Java.  The good news,
> though, is that you will rarely have to compile things on the iSeries.
> In fact, I never compile on the iSeries anymore.  I do all my work on
> the PC (including testing!) and then simply transfer the compiled code,
> either .class files or .jar files, to the iSeries for integration
> testing.
>
>
> Joe
>
>
>> From: Luqman
>>
>> Whenever I logon to AS/400, I type following, because my HELLO.JAVA is
> in
>> /root/JAVA folder.
>>
>> CD JAVA
>> STRQSH
>> JAVAC HELLO.JAVA
>>
>> Even I tried JAVAC HELLO.JAVA but following displayed on screen.
>
> -- 
> This is the Java Programming on and around the iSeries / AS400 (JAVA400-L) 
> mailing list
> To post a message email: JAVA400-L@xxxxxxxxxxxx
> To subscribe, unsubscribe, or change list options,
> visit: http://lists.midrange.com/mailman/listinfo/java400-l
> or email: JAVA400-L-request@xxxxxxxxxxxx
> Before posting, please take a moment to review the archives
> at http://archive.midrange.com/java400-l.
>
> 




As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

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.