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



As David suggests, you are far better off starting out on the PC.  In
QShell, the problem you are describing could be do to issues in file
naming, directories, classpath, who knows what.  If you insist on
pushing through with this, I would suggest one quick check: execute the
command "ls" (no quotes).  This will list the contents of the current
directory.  If hello.java is there, you can compile it.  But notice also
that you named the file incorrectly anyway.  It would have to be named
"HelloWorld.java" in order to compile.

I highly suggest installing WDSC on your PC and starting there.  There
is no tool out there like WDSC.  WDSC stands for WebSphere Studio Client
for iSeries and if you have an iSeries that has a current license to the
compilers (5722WDS) then you can get a copy of WDSC.

Joe

> -----Original Message-----
> From: java400-l-bounces+lists=plutabrothers.com@xxxxxxxxxxxx
> [mailto:java400-l-bounces+lists=plutabrothers.com@xxxxxxxxxxxx] On
Behalf
> Of Luqman
> Sent: Sunday, August 28, 2005 10:03 AM
> To: java400-l@xxxxxxxxxxxx
> Subject: Re: Compiling Hello.java with javac ?
> 
> 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.
> >
> >
> 
> 
> 
> --
> 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 ...

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.