• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to practise the sample code + how to install eclipse

 
Priyadarshni Gopalakrishnan
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi JavaRanchers,

I am a beginner .... in the truest sense.. I have been desperately trying to install eclipse IDE in my comp.. I have JDK 1.5 and JRE 1.5 installed in my system.. though Head First suggests to try out the code examples in text editor..

I would like to go in for IDE ..coz.. I am new to programming also.. I have downloaded Eclipse 3.1 SDK Win32.. though I tried running eclipsec and the exe file , it doesnt get installed.. Please help..
 
neilson ramalho
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
well, if you want to start working as soon as possible, I suggest you to download Netbeans 6.0, but believe me, you are not gonna learn as much as if you were using a text editor.
But, before going to J2EE, it would be better for you to get a good background with the Standard Edition first.
If you do want to use Eclipse, try Eclipse Europa...
http://www.eclipse.org/downloads/moreinfo/jee.php
What do you get when you try to install Eclipse? any error messages?
maybe you didn't install JDK correctly...
 
neilson ramalho
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
if you are already familiar with another programming language and want to learn Java, I suggest you
http://www.amazon.com/exec/obidos/ASIN/0072226846/jr_bunk-20
check the Bunkhouse section out...
This book goes right to the point.
As a C programmer, that's what I used to learn Java and get SCJP. However, if you are really new to programming, try to get easier with
http://www.amazon.com/exec/obidos/ASIN/0596004656/jr_bunk-20
[ April 08, 2008: Message edited by: neilson ramalho ]
 
Anubhav Anand
Ranch Hand
Posts: 341
Firefox Browser Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Priyadarshni Gopalakrishnan:
Hi JavaRanchers,

I am a beginner .... in the truest sense.. I have been desperately trying to install eclipse IDE in my comp.. I have JDK 1.5 and JRE 1.5 installed in my system.. though Head First suggests to try out the code examples in text editor..

I would like to go in for IDE ..coz.. I am new to programming also.. I have downloaded Eclipse 3.1 SDK Win32.. though I tried running eclipsec and the exe file , it doesnt get installed.. Please help..


Well as you quote, notepad is the proper way to start with for beginners.
I stress the use of notepad.

Well, if you really want to rush into the IDE, then eclipse doesn't needs to be installed. You just have to unzip the contents and then you can start the ide by clicking on the eclipse.exe
 
Campbell Ritchie
Sheriff
Pie
Posts: 50171
79
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I agree with the people who are warning against using IDEs, but you would do better to use Notepad++ or similar as a text editor. When you tell it you are saving a Java file, you get context highlighting, matching of () when you put your mouse on them, and automatic indentation, which all make your code much easier to read.
 
neilson ramalho
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
great, Campbell. I had forgetten about Notepadd++.
That's a nice tool, but unfortunately it's not available for Linux users (without wine).
By the other hand, we have a bunch of other cool editors such as jEdit and SciTE (both available for Windows).
[]'s
neilson
 
Anubhav Anand
Ranch Hand
Posts: 341
Firefox Browser Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well as Notepad++ is on Windows, one can use gedit on Linux.
 
Priyadarshni Gopalakrishnan
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Neil,Anubhav and Ritchie,

Thank you so much for the suggestions.. I have Netbeans installed already..but some of friends suggested Eclipse for trying out sample code.. any ways ..I'll go with notepad first and then ..go for IDEs.

Thanks again.
 
Richard Chambers
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can I hop in with a stupid question about NetBeans?

I looked at it for doing my schoolwork (yeah I know)

The typical assignment I have to write a couple files of java
but the instructor provides an accompanying class file that is part of
the program.

how do I import that class file (without the java source code file)
into my package.
 
Amit Ghorpade
Bartender
Posts: 2854
10
Fedora Firefox Browser Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, Richard,
Well it seems that your question is not specific to Netbeans,
you can simply write an import statement in your code to import that particular class file, and set the appropriate classpath if need be.


Hope this helps
 
f. nikita thomas
Ranch Hand
Posts: 87
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Richard Chambers:
Can I hop in with a stupid question about NetBeans?

I looked at it for doing my schoolwork (yeah I know)

The typical assignment I have to write a couple files of java
but the instructor provides an accompanying class file that is part of
the program.

how do I import that class file (without the java source code file)
into my package.


hey richard,
one of the reasons that so many people are stressing the use of just editors is that is forces you to interpret compiler output on your own. if your instructor provided a *.java or *.class file to include in your project, all that is necessary is that it is in the same directory your source (*.java) file is in. my instructor provided our class with Textpad which has syntax highlighting as well as keystrokes(ctl-1/ctl-2) to compile and run the code. this is as close as you should come to an ide for awhile. i don't use textpad myself, emacs or vi for me !



[ April 10, 2008: Message edited by: f. nikita thomas ]
 
Raghavan Muthu
Ranch Hand
Posts: 3381
Mac MySQL Database Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Priyadarshni Gopalakrishnan:
.. I have Netbeans installed already..but some of friends suggested Eclipse for trying out sample code..


Well it does not make any difference at all. May be you get a different look and feel and little significant features!

As all others suggested, you better start off with an editor and run your programs in Command Prompt (using "java" executable). You will learn a lot
 
Raghavan Muthu
Ranch Hand
Posts: 3381
Mac MySQL Database Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Richard Chambers:
..
how do I import that class file (without the java source code file)
into my package.


Well Amit has answered correctly. On top of this, even though you have the .java source file it is not considered at all. May be for an end-users perspective, you have a look at the .java file in the editor.

But what happens when you run/execute the file? It is all with .class file. The same goes with importing also. You can directly go ahead and import the class with its package name if it is a part of any.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic