Forum     

Go Back   Digit Technology Discussion Forum > Portables, Peripherals and Electronics > QnA (read only)
Register FAQ Calendar Mark Forums Read

QnA (read only) Mods please help transfer the contents of this forum to proper sections. :)


 
 
LinkBack Thread Tools Search this Thread Display Modes
Old 09-09-2004, 07:20 AM   #1 (permalink)
Right Off the Assembly Line
 
Join Date: Sep 2004
Posts: 2
Default SOS: Faulty Java Interpreter


i have windows XP sp1, athlon 2000+, 256Mb RAM and nforce m/b with 40GB baracudda. i recently installed JDK1.5. the problem is that when i compile my program from console, they compile fine, but when i exceute them with (java) interpreter i get an error :
exception in "main" noclassdeffounderror: demo (<-- file name)

the same jdk worked fine earlier.

please can anyone guide me?
poweruser is offline  
Advertisements. Register and be a member of the community to get rid of them.
Advertisement

Old 09-09-2004, 08:21 AM   #2 (permalink)
Wise Old Owl
 
aadipa's Avatar
 
Join Date: Feb 2004
Location: Palghar, Mumbai
Posts: 1,000
Default

check for CLASSPATH environmental variable.

if u don't use "package" for ur program then, classpath should be current directory.

try this command before running ur program
SET CLASSPATH=.

or if u have some extra library files then
SET CLASSPATH=%CLASSPATH%;.

this should solve ur problem
__________________
i generally prefer quality over quantity
1 aadi + 1 aadi = 1 full ;)
aadipa is offline  
Old 09-09-2004, 08:30 AM   #3 (permalink)
Right Off the Assembly Line
 
Join Date: Sep 2004
Posts: 2
Default classpath set

i have tried everything from setting the classpath to reinstalling the jdk1.5. i even installed jdk1.3 , but again i am able to compile programs from the console yet it gives problem regarding the execution
poweruser is offline  
Old 09-09-2004, 01:10 PM   #4 (permalink)
FooBar Guy
 
GNUrag's Avatar
 
Join Date: Jun 2004
Location: GNUmbai
Posts: 1,245
Default

Change your environment variable settings in windows XP and add a new env variable called CLASSPATH

CLASSPATH=C:\jdk1.5\jre\lib\rt.jar;.

notice the dot in the last. If this doesnt work then you sure are not following the steps right...
__________________
- --
http://web.gnuer.org
GNUrag is offline  
Old 09-09-2004, 03:15 PM   #5 (permalink)
Right Off the Assembly Line
 
Join Date: Sep 2003
Location: india
Posts: 3
Default jdk 1.5

1. I haven't work with the RC1, but older betas of 1.5 , and also the prototype compilers. If the demo you are compiling is for somethin specific for java 1.5 (like generics),
To compile with Beta version use:

javac -source 1.5 aa.java

2. anyway , first try checking that the class defined inside demo.java is not Demo.java (d-D) or something (to err, as they say.....)

Hope it helps. Please keep us posted abt. the result.
-Rahul
rahul is offline  
Old 09-09-2004, 03:18 PM   #6 (permalink)
Right Off the Assembly Line
 
Join Date: Sep 2003
Location: india
Posts: 3
Default Re: jdk 1.5

Quote:
Originally Posted by rahul
2. anyway , first try checking that the class defined inside demo.java is not Demo.java (d-D) or something (to err, as they say.....)

-Rahul
I meant "class defined inside demo.java is not Demo (d-D) or something "

No wonder the forum lists me as Analogue Novice
rahul is offline  
Old 09-09-2004, 03:35 PM   #7 (permalink)
FooBar Guy
 
GNUrag's Avatar
 
Join Date: Jun 2004
Location: GNUmbai
Posts: 1,245
Default Re: jdk 1.5

Quote:
Originally Posted by rahul
No wonder the forum lists me as Analogue Novice
Every In-house-geek was an Analog Novice some day !!! and as you said... to err is human... you could have edited your post instead of making a new post...
__________________
- --
http://web.gnuer.org
GNUrag is offline  
 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


 
Latest Threads
- by topgear

Advertisement




All times are GMT +5.5. The time now is 08:56 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.

Search Engine Optimization by vBSEO 3.3.2