Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Java Programmer > Re: Help runnin...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 6 of 14 Topic 52662 of 55512
Post > Topic >>

Re: Help running a very very very simple code

by fchang@[EMAIL PROTECTED] May 12, 2008 at 06:33 AM

This message is in MIME format.  The first part should be readable text,
  while the remaining parts are likely unreadable without MIME-aware
tools.

---559023410-851401618-1210599191=:27362
Content-Type: TEXT/PLAIN; charset=windows-1252; format=flowed
Content-Transfer-Encoding: 8BIT

On Mon, 12 May 2008, Aryeh M. Friedman wrote:
>
> olivier.melcher wrote:
> > package myfirstproject;
> > 
> > class MyFirstJavaClass {
> >    public static void main(String[] args) {
> >      System.out.println(“chocolate, royalties, sleep”);
> >     }
> > }
>
> What happens if you compile from the command line:
>
> cd /home/olivier/NetBeansProjects/MyFirstProject/src/myfirstproject/
> javac MyFirstJavaClass.java
> java MyFirstJavaClass

Actually, since the class is under the "myfirstproject" package,
the legal way to compile it from the command line must be done
from the directory ABOVE it:

cd /home/olivier/NetBeansProjects/MyFirstProject/src/
javac myfirstproject/MyFirstJavaClass.java
java -cp . myfirstproject.MyFirstJavaClass



---559023410-851401618-1210599191=:27362--
 




 14 Posts in Topic:
Help running a very very very simple code
"olivier.melcher&quo  2008-05-12 06:14:06 
Re: Help running a very very very simple code
"Aryeh M. Friedman&q  2008-05-12 09:26:56 
Re: Help running a very very very simple code
ram@[EMAIL PROTECTED] (S  2008-05-12 13:32:15 
Re: Help running a very very very simple code
ram@[EMAIL PROTECTED] (S  2008-05-12 13:36:46 
Re: Help running a very very very simple code
Lew <lew@[EMAIL PROTEC  2008-05-12 10:30:31 
Re: Help running a very very very simple code
fchang@[EMAIL PROTECTED]   2008-05-12 06:33:11 
Re: Help running a very very very simple code
Tom McGlynn <tam@[EMAI  2008-05-12 06:33:47 
Re: Help running a very very very simple code
Sabine Dinis Blochberger   2008-05-12 15:08:58 
Re: Help running a very very very simple code
ram@[EMAIL PROTECTED] (S  2008-05-12 14:17:21 
Re: Help running a very very very simple code
Lew <lew@[EMAIL PROTEC  2008-05-12 10:35:33 
Re: Help running a very very very simple code
Sabine Dinis Blochberger   2008-05-12 16:47:21 
Re: Help running a very very very simple code
Lew <lew@[EMAIL PROTEC  2008-05-12 19:59:23 
Re: Help running a very very very simple code
Roedy Green <see_websi  2008-05-12 17:46:51 
Re: Help running a very very very simple code
Oliv <olivier.melcher@  2008-05-12 12:51:07 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Wed Dec 3 14:13:42 CST 2008.