File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Can anybody help me? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Can anybody help me?" Watch "Can anybody help me?" New topic

Can anybody help me?

kishore chitturi
Ranch Hand

Joined: Nov 28, 2004
Posts: 50
I installed jdk1.5 and i set classpath and path also.If i run a sample program , following exception occured.Can any body suggest me,why this exception is coming?

Exception in thread "main" java.lang.NoClassDefFoundError: Example
Roman Tomach

Joined: Mar 17, 2005
Posts: 15
Try to add .(dot) to classpath variable.
John Wolf
Ranch Hand

Joined: Feb 18, 2002
Posts: 64
In Wintel command prompt, type


in UNIX prompt, type


to make sure your classpath is setup correctly.

Or as suggested by Roman type

java -cp . classname

Good Luck!
[ June 01, 2005: Message edited by: Sumit Sadana ]

SCJP 1.2, SCJP 1.4, SCJA, SCWCD 1.4<br /> <br />------------------------------<br />
I agree. Here's the link:
subject: Can anybody help me?
It's not a secret anymore!