944,098 Members | Top Members by Rank

Ad:
  • Java Discussion Thread
  • Unsolved
  • Views: 1187
  • Java RSS
Aug 19th, 2006
0

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

Expand Post »
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...........
Reputation Points: 10
Solved Threads: 0
Newbie Poster
Cyrus_DB is offline Offline
11 posts
since Jun 2006
Aug 20th, 2006
1

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

Ohh, you have an environment variable issue. Check the java.sun site to get the latest info on how to correctly set your variables.
Reputation Points: 113
Solved Threads: 19
Postaholic
server_crash is offline Offline
2,108 posts
since Jun 2004

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in Java Forum Timeline: StringTokenizer
Next Thread in Java Forum Timeline: Change Image based on user Input





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC