• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

jdk 6 no material or anything

polarbear6

Golden Member
hey i am basically not a programmer but have done many stuff with c++ and vb and vc++ and vc#

but iam more a web programmer
but recently for my friends college fest i decided to give java a shot

so can anyone help me out like what do i need and where to begin
i have jdk but when i compile a class file i get this error
"eception in thread "main" java.lang.no classdeffound error: hello/java"
and few more lines .......

note : i have tried a small file which i got at sun's website"hello.java"

so any help on this would be appreciated
i heard my friend saying something about setting the global variables ......

i use vista ultimate 32bit


 
Looks like some kind of confusion between the path function of "." (where it refers to a class' path when running java.exe) and the filename.

Did you use javac.exe to compile the class first? The way to run a .java file, in other words (and assuming no packages) is:

C> javac file.java
rem This creates the file "file.class" which you then run with:
C> java file
rem No ".class" on the end; that's assumed.
 
yeah i just figured how to make jdk work in vista but now the new problem is that i cannot create .class files from command prompt cause i have been denied access on my own pc
by the stupid os

hell regreting so much that i gave up xp 🙁(
i miss u baby
 
Wow, I don't have Vista, and now I have yet another reason to avoid it.

If it were Linux, you could just use "sudo". And it looks like there is a sudo for Vista.

If you're wondering how "sudo" works, XKCD can explain. 😉
 
You have to understand how UAC works. It won't let your user account write to privileged locations without authorization first. There are three ways to fix it, turn off UAC(bad idea), change folder permissions(bad idea), or change where you are writing your files to. Always work under your C:\Users\<account name> folder and you won't have this issue. If you have a separate partition you work on make sure your user account has read/write privileges where you trying to work.
 
Back
Top