By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,798 Members | 1,342 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,798 IT Pros & Developers. It's quick & easy.

Java IDE for Beginners

P: n/a
JD
hi, i m new to java, i want to know if there is a good and free Java IDE
that i can use that'll help me, i dont care if its complicated , i just
want it to be good, i tried netbeans which comes bundled with java sdk 6
from sun, the prob with it is that , if i use for-each loop, it says to
use option -source 1.5, i used it, didnt work, so either the IDE is
faulty, or somethin is wrong with my sys config. so, can anyone
recommend an IDE for me?
Jan 2 '07 #1
Share this Question
Share on Google+
17 Replies


P: n/a
cp
You can try Eclipse. Its quites powerfull and you can download alot of
plugins to it for free.
Jan 2 '07 #2

P: n/a
JD wrote:
hi, i m new to java, i want to know if there is a good and free Java IDE
that i can use that'll help me, i dont care if its complicated , i just
want it to be good, i tried netbeans which comes bundled with java sdk 6
from sun, the prob with it is that , if i use for-each loop, it says to
use option -source 1.5, i used it, didnt work, so either the IDE is
faulty, or somethin is wrong with my sys config. so, can anyone
recommend an IDE for me?
Well the other popular free IDE is Eclipse: http://www.eclipse.org

If I was just starting out with Java I would not user Netbeans nor
Eclipse. You will spend a lot of time figuring out the IDE and its
functionality and not the Java language.

I would start with an IDE called 'BlueJ' http://www.bluej.org
It is a simpler interface and it will teach you how to program Java with
an OOD\OOP approach.

They also have worked with the Netbeans development people and have just
release a BlueJ-Netbeans version.

--
Thanks in Advance... http://ichbinquotations.awardspace.com
IchBin, Pocono Lake, Pa, USA http://ichbin.9999mb.com
__________________________________________________ ____________________
'If there is one, Knowledge is the "Fountain of Youth"'
-William E. Taylor, Regular Guy (1952-)
Jan 2 '07 #3

P: n/a
Lew
IchBin wrote:
JD wrote:
>hi, i m new to java, i want to know if there is a good and free Java IDE
that i can use that'll help me, i dont care if its complicated , i just
want it to be good, i tried netbeans which comes bundled with java sdk 6
from sun, the prob with it is that , if i use for-each loop, it says to
use option -source 1.5, i used it, didnt work, so either the IDE is
faulty, or somethin is wrong with my sys config.
Or you made a mistake, which is by far the most likely. I use Netbeans and
have not received such a message.

Why don't you post the construct that is failing? (Copy-and-paste it; do not
paraphrase.)

- Lew
Jan 2 '07 #4

P: n/a
JD
Lew wrote:
IchBin wrote:
>JD wrote:
>>hi, i m new to java, i want to know if there is a good and free Java IDE
that i can use that'll help me, i dont care if its complicated , i just
want it to be good, i tried netbeans which comes bundled with java sdk 6
from sun, the prob with it is that , if i use for-each loop, it says to
use option -source 1.5, i used it, didnt work, so either the IDE is
faulty, or somethin is wrong with my sys config.

Or you made a mistake, which is by far the most likely. I use Netbeans
and have not received such a message.

Why don't you post the construct that is failing? (Copy-and-paste it; do
not paraphrase.)

- Lew
public class VariableArgumentList {
for(int a,a<=10;a++);

/** Creates a new instance of VariableArgumentList */
public static void main(String[] args) {
printAll(2,"two",4,"Four",4.5,"Four Point Five");
printAll();
printAll(25,"Anything Goes",4E4,false);
}
public static void printAll(Object ... args){ // Error Here
for(Object a:args){ // Error Here
System.out.println(a);

}
}

}
here's the class. it wants to use -source 1.5 option, i gave it, but
still nothing, i already did a clean install of the setup bout 5 times
now, still it persists.
Jan 2 '07 #5

P: n/a
JD
Scratch Last code, this is the correct code.

public class VariableArgumentList {
// Removed faulty code from here.
/** Creates a new instance of VariableArgumentList */
public static void main(String[] args) {
printAll(2,"two",4,"Four",4.5,"Four Point Five");
printAll();
printAll(25,"Anything Goes",4E4,false);
}
public static void printAll(Object ... args){ // Error Here
for(Object a:args){ // Error Here
System.out.println(a);

}
}

}
Jan 2 '07 #6

P: n/a
JD wrote:
Scratch Last code, this is the correct code.

public class VariableArgumentList {
// Removed faulty code from here.
/** Creates a new instance of VariableArgumentList */
public static void main(String[] args) {
printAll(2,"two",4,"Four",4.5,"Four Point Five");
printAll();
printAll(25,"Anything Goes",4E4,false);
}
public static void printAll(Object ... args){ // Error Here
A method can not have a parm list the way you have it defined.
Could do it this way:

public static void printAll(int v1, String v2, int v3 String v4, float
v5,String v6 ){

Or create an arraylist with the stuff you want to print and then pass that.
for(Object a:args){ // Error Here
System.out.println(a);

}
}

}
Your code is completely wrong.

You need to look at the Java documentation for calling and passing data
to a method.

You need to be reading up on Java in of these places:

The Java Language Specification, Third Edition
http://java.sun.com/docs/books/jls/t...tml/j3TOC.html

The Really Big Index (A list of all content pages in the The Java Tutorial)
http://java.sun.com/docs/books/tutor...ybigindex.html

Java Platform, Standard Edition 6 API Specification
http://java.sun.com/javase/6/docs/api

The Java Developers Almanac
http://www.exampledepot.com

--
Thanks in Advance... http://ichbinquotations.awardspace.com
IchBin, Pocono Lake, Pa, USA http://ichbin.9999mb.com
__________________________________________________ ____________________
'If there is one, Knowledge is the "Fountain of Youth"'
-William E. Taylor, Regular Guy (1952-)
Jan 3 '07 #7

P: n/a
JD
IchBin wrote:
JD wrote:
>Scratch Last code, this is the correct code.

public class VariableArgumentList {
// Removed faulty code from here.
/** Creates a new instance of VariableArgumentList */
public static void main(String[] args) {
printAll(2,"two",4,"Four",4.5,"Four Point Five");
printAll();
printAll(25,"Anything Goes",4E4,false);
}
public static void printAll(Object ... args){ // Error Here

A method can not have a parm list the way you have it defined.
Could do it this way:

public static void printAll(int v1, String v2, int v3 String v4, float
v5,String v6 ){

Or create an arraylist with the stuff you want to print and then pass that.
> for(Object a:args){ // Error Here
System.out.println(a);

}
}

}
Your code is completely wrong.

You need to look at the Java documentation for calling and passing data
to a method.

You need to be reading up on Java in of these places:

The Java Language Specification, Third Edition
http://java.sun.com/docs/books/jls/t...tml/j3TOC.html

The Really Big Index (A list of all content pages in the The Java Tutorial)
http://java.sun.com/docs/books/tutor...ybigindex.html

Java Platform, Standard Edition 6 API Specification
http://java.sun.com/javase/6/docs/api

The Java Developers Almanac
http://www.exampledepot.com
i tried this exact same code on eclipse IDE (besides, netbeans is far
better than eclipse, especially for beginners like me coz it gives
popups with explaination of methods) and it works, i tried this exact
code using javac.exe , it works, i m using the book form WROX called
ivor horton's beginning java sdk 5. the for-each loop and the new
parameter passing was introduced in jdk 5, i can do it another way, but
i wanna try this way to learn it, i like netbeans, but it looks like
that i really have no choice but to go for eclipse.

besides, does JRE has anything to do with netbeans, i have JRE 5
installed. but i have JDK 6.
Jan 3 '07 #8

P: n/a
IchBin wrote:
JD wrote:
>Scratch Last code, this is the correct code.

public class VariableArgumentList {
// Removed faulty code from here.
/** Creates a new instance of VariableArgumentList */
public static void main(String[] args) {
printAll(2,"two",4,"Four",4.5,"Four Point Five");
printAll();
printAll(25,"Anything Goes",4E4,false);
}
public static void printAll(Object ... args){ // Error Here

A method can not have a parm list the way you have it defined.
Could do it this way:

public static void printAll(int v1, String v2, int v3 String v4, float
v5,String v6 ){

Or create an arraylist with the stuff you want to print and then pass that.
> for(Object a:args){ // Error Here
System.out.println(a);

}
}

}
Your code is completely wrong.

You need to look at the Java documentation for calling and passing data
to a method.

You need to be reading up on Java in of these places:

The Java Language Specification, Third Edition
http://java.sun.com/docs/books/jls/t...tml/j3TOC.html

The Really Big Index (A list of all content pages in the The Java Tutorial)
http://java.sun.com/docs/books/tutor...ybigindex.html

Java Platform, Standard Edition 6 API Specification
http://java.sun.com/javase/6/docs/api

The Java Developers Almanac
http://www.exampledepot.com
Very sorry.. I should have tested the code. I have never seen a method
have an argument list like this.. Guess I should read those docs.

--
Thanks in Advance... http://ichbinquotations.awardspace.com
IchBin, Pocono Lake, Pa, USA http://ichbin.9999mb.com
__________________________________________________ ____________________
'If there is one, Knowledge is the "Fountain of Youth"'
-William E. Taylor, Regular Guy (1952-)
Jan 3 '07 #9

P: n/a
Lew
JD wrote:
public class VariableArgumentList {
for(int a,a<=10;a++);
This is not valid 'for' syntax. It is also not valid to have a 'for' statement
outside of a method in this way. Isn't there a compiler error on this line?
/** Creates a new instance of VariableArgumentList */
Not actually what main() does.
public static void main(String[] args) {
printAll(2,"two",4,"Four",4.5,"Four Point Five");
printAll();
printAll(25,"Anything Goes",4E4,false);
}
public static void printAll(Object ... args){ // Error Here
for(Object a:args){ // Error Here
System.out.println(a);

}
}

}
What is the exact text of the error messages?

- Lew
Jan 5 '07 #10

P: n/a
Lew
JD wrote:
i tried this exact same code on eclipse IDE (besides, netbeans is far
better than eclipse, especially for beginners like me coz it gives
popups with explaination of methods) and it works, i tried this exact
code using javac.exe , it works, i m using the book form WROX called
ivor horton's beginning java sdk 5. the for-each loop and the new
parameter passing was introduced in jdk 5, i can do it another way, but
i wanna try this way to learn it, i like netbeans, but it looks like
that i really have no choice but to go for eclipse.

besides, does JRE has anything to do with netbeans, i have JRE 5
installed. but i have JDK 6.
I use Netbeans 5.5 with JDK 6 and it accepts these constructs just fine. But
you must hook your project up to a JDK, not a JRE.

From the Netbeans menu: "Tools / Java Platform Manager".

What are the exact error messages you get?

- Lew
Jan 5 '07 #11

P: n/a
JD wrote:
Lew wrote:
>IchBin wrote:
>>JD wrote:
hi, i m new to java, i want to know if there is a good and free Java
IDE that i can use that'll help me, i dont care if its complicated , i
just want it to be good, i tried netbeans which comes bundled with java
sdk 6 from sun, the prob with it is that , if i use for-each loop, it
says to use option -source 1.5, i used it, didnt work, so either the
IDE is faulty, or somethin is wrong with my sys config.

Or you made a mistake, which is by far the most likely. I use Netbeans
and have not received such a message.

Why don't you post the construct that is failing? (Copy-and-paste it; do
not paraphrase.)

- Lew

public class VariableArgumentList {
for(int a,a<=10;a++);

/** Creates a new instance of VariableArgumentList */
public static void main(String[] args) {
printAll(2,"two",4,"Four",4.5,"Four Point Five");
printAll();
printAll(25,"Anything Goes",4E4,false);
}
public static void printAll(Object ... args){ // Error Here
for(Object a:args){ // Error Here
System.out.println(a);

}
}

}
here's the class. it wants to use -source 1.5 option, i gave it, but
still nothing, i already did a clean install of the setup bout 5 times
now, still it persists.
I'm a little rusty in Java, but the following should meet your purpose.

public class VariableArgumentList
{
// Creates a new instance of VariableArgumentList
VariableArgumentList()
{
private String[] arguments = { "2", "two", "4", "Four" }; // add more
args to print out if you want
}

public static void main( String[] args )
{
for ( i = 0; i < arguments.length(); i++ )
{
System.out.println( arguments[i] + "\n" );
}
}
}
Jan 6 '07 #12

P: n/a
Lew
Sean Fritz wrote:
public class VariableArgumentList
{
// Creates a new instance of VariableArgumentList
VariableArgumentList()
{
private String[] arguments = { "2", "two", "4", "Four" }; // add more
args to print out if you want
}

public static void main( String[] args )
{
for ( i = 0; i < arguments.length(); i++ )
{
System.out.println( arguments[i] + "\n" );
}
}
}
This doesn't help resolve the OP's issues with getting variable argument lists
to work, that is, the language construct where you declare a method as

<access-specifier<return-typeFoo( T ... args );

Also, your example as posted won't compile. There is no declaration of the
variable 'arguments' in the main method. There is no declaration of the
variable 'arguments' as an instance variable. The 'private' access specifier
inside the constructor won't work. The index variable i in the for() loop is
not declared. Array length is found by the array instance variable 'length',
not a method 'length()'.

- Lew
Jan 6 '07 #13

P: n/a
kn
I perfer eclipse, but I have to use netbeans at work, so I'm familiar with
both.
In projects I've worked on eclipse is better (for me) - it works faster,
builds faster,
does refactoring better, shows warnings, offers better quick-fix solutions,
has smarter code assist and I like cvs support better.
However, netbeans has (except warnings) all that features too (only not as
nice), and
has far superior gui designer.

People new to java usally like netbeans more, for no particular reason. I
would suggest
eclipse to a beginner because it shows lots of useful warnings that will
teach you to write nicer code.

"JD" <jo*********@gmail.comwrote in message
news:zv******************************@giganews.com ...
hi, i m new to java, i want to know if there is a good and free Java IDE
that i can use that'll help me, i dont care if its complicated , i just
want it to be good, i tried netbeans which comes bundled with java sdk 6
from sun, the prob with it is that , if i use for-each loop, it says to
use option -source 1.5, i used it, didnt work, so either the IDE is
faulty, or somethin is wrong with my sys config. so, can anyone
recommend an IDE for me?

Jan 9 '07 #14

P: n/a
kn wrote:
I perfer eclipse, but I have to use netbeans at work, so I'm familiar with
both.
In projects I've worked on eclipse is better (for me) - it works faster,
builds faster,
does refactoring better, shows warnings, offers better quick-fix solutions,
has smarter code assist and I like cvs support better.
However, netbeans has (except warnings) all that features too (only not as
nice), and
has far superior gui designer.

People new to java usally like netbeans more, for no particular reason. I
would suggest
eclipse to a beginner because it shows lots of useful warnings that will
teach you to write nicer code.

"JD" <jo*********@gmail.comwrote in message
news:zv******************************@giganews.com ...
>hi, i m new to java, i want to know if there is a good and free Java IDE
that i can use that'll help me, i dont care if its complicated , i just
want it to be good, i tried netbeans which comes bundled with java sdk 6
from sun, the prob with it is that , if i use for-each loop, it says to
use option -source 1.5, i used it, didnt work, so either the IDE is
faulty, or somethin is wrong with my sys config. so, can anyone
recommend an IDE for me?

IMHO - I disagree. For a beginner in the Java Language, IF new to
programming, to use straight Java, Javac and a text editor. Using a
professional IDE for Java at this point would be very confusing. They
need to get the Java fundamentals down first.

If you have programming experience with other languages and IDE's then
no problem with Eclipse, Netbeans or Sun's Sun Java Studio.

I guess if the OP does not care about complexity. I guess my comments
maybe mute.

--
Thanks in Advance... http://weconsul.zendurl.com
IchBin, Pocono Lake, Pa, USA http://ichbinquotations.awardspace.com
__________________________________________________ ____________________
'If there is one, Knowledge is the "Fountain of Youth"'
-William E. Taylor, Regular Guy (1952-)
Jan 9 '07 #15

P: n/a
kn
IMHO - I disagree. For a beginner in the Java Language, IF new to
programming, to use straight Java, Javac and a text editor. Using a
professional IDE for Java at this point would be very confusing. They need
to get the Java fundamentals down first.
I do agree with you. When I was a beginner my IDE was Notepad. How I hated
java case sensitivity when I swithced from MS Basic back then ;)

However JD specifically asked about an IDE so I shared my experiences with
IDEs I tried.
Jan 11 '07 #16

P: n/a
kn wrote:
>IMHO - I disagree. For a beginner in the Java Language, IF new to
programming, to use straight Java, Javac and a text editor. Using a
professional IDE for Java at this point would be very confusing. They need
to get the Java fundamentals down first.

I do agree with you. When I was a beginner my IDE was Notepad. How I hated
java case sensitivity when I swithced from MS Basic back then ;)

However JD specifically asked about an IDE so I shared my experiences with
IDEs I tried.

Cool.. no problem

--
Thanks in Advance... http://weconsul.zendurl.com
IchBin, Pocono Lake, Pa, USA http://ichbinquotations.awardspace.com
__________________________________________________ ____________________
'If there is one, Knowledge is the "Fountain of Youth"'
-William E. Taylor, Regular Guy (1952-)
Jan 11 '07 #17

P: n/a
Using an IDE can be dangerous if you don't learn a language properly.

Having said that I don't believe in the whole "use notepad to learn"
theory.

I would suggest using JCreator LE http://www.jcreator.com/

It's the free version, it loads fast and it won't be as confusing as
Eclipse or Netbeans to a newcomer.

I know you said you don't care if something is complicated but if you
want to learn properly you can't start off worrying about all the aspects
of the IDE. You need to focus on the language only.

On Tue, 02 Jan 2007 19:23:02 +0500, JD wrote:
hi, i m new to java, i want to know if there is a good and free Java IDE
that i can use that'll help me, i dont care if its complicated , i just
want it to be good, i tried netbeans which comes bundled with java sdk 6
from sun, the prob with it is that , if i use for-each loop, it says to
use option -source 1.5, i used it, didnt work, so either the IDE is
faulty, or somethin is wrong with my sys config. so, can anyone
recommend an IDE for me?
spammer -en*******@optimaloptimization.com
Apr 6 '08 #18

This discussion thread is closed

Replies have been disabled for this discussion.