Help............

Reply

Join Date: Jun 2006
Posts: 11
Reputation: Cyrus_DB is an unknown quantity at this point 
Solved Threads: 0
Cyrus_DB Cyrus_DB is offline Offline
Newbie Poster

Help............

 
0
  #1
Aug 19th, 2006
I'm a beginner in JAVA and I'm facing a problem in executing a sample program.Let me explain it step by step:

1. The following program was written thru a notepad and then saved as Sample.java:

class Sample
{
public static void main(String args[])
{
System.out.println("Hello World!!!");
}
}

2. The above program is then compiled by rhe following command:

javac Sample.java

Successful compilation: a .CLASS file named as Sample.class was generated.

3.The following command was implemented for execution:

java Sample

An error message appeared:

Exception in thread 'main':java.lang.NoClassDef Found.Errorample

PLEASE HELP...........
Reply With Quote Quick reply to this message  
Join Date: Jun 2004
Posts: 2,108
Reputation: server_crash is on a distinguished road 
Solved Threads: 18
server_crash server_crash is offline Offline
Postaholic

Re: Help............

 
1
  #2
Aug 20th, 2006
Ohh, you have an environment variable issue. Check the java.sun site to get the latest info on how to correctly set your variables.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Other Threads in the Java Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC