Skip to main content

Compiling Java files

5 replies [Last post]
vitty85
Offline
Joined: 2007-07-20
Points: 0

hi all....i can't run any class file i've created with netbeans and java 1.6 but i can run the helloworld example so i'm sure that the jvm works fine....someone could tell me wich ide i've have to use in order to compile class file in a right way? and also wich version of jdk is compatible with personal profile?

Thanks...

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
cjplummer
Offline
Joined: 2006-10-16
Points: 0

You need to compile with "-source 1.4 -target 1.4".

Chris

vitty85
Offline
Joined: 2007-07-20
Points: 0

so i've to compile it by command line passing these two arguments??

and is not possible to use an editor like eclipse to manage bigger application?

Message was edited by: vitty85

cjplummer
Offline
Joined: 2006-10-16
Points: 0

I'm not a java IDE user, so I don't know how to get them to compile with these options, but I'm pretty sure it is possible.

Chris

vitty85
Offline
Joined: 2007-07-20
Points: 0

i found a way to do this in eclipse...thanks for the string....

dmocek
Offline
Joined: 2004-06-30
Points: 0

Vitty,

to set build properties in NetBeans, right mouse-click your project and select 'Properties'. Select 'Compiling, under 'Build' in the 'Categories' list. There you'll see an edit box titled 'Additional Compiler Options'. Set the '-source 1.4 -target 1.4' options (no quotes) there.