Got a little techonology problem that you need fixed pronto? Post it here and we'll see what we can do.
Topic locked

Java: Just a quick question

Tue Nov 09, 2004 9:13 pm

My parents ask me to compile a christmas list, and I want to ask a quick question.

I really want to learn Java - not javascript - and I was wondering whether it needs a specific programme, such as the Basics, to make, or whether you can just type it into a text document, such as HTML and Javascript.

Thanks in advance for your answer

~ Matt :)

Tue Nov 09, 2004 10:37 pm

You need a Java compiler, such as JCreator or JBuilder. JCreator is free at http://www.jcreator.com/

JBuilder, though, is a program made by Borland and you need to purchase it.

Google around for some tutorials on Java, and make sure to learn some basic methods using the Java API at http://java.sun.com/ The best way to learn Java is through a book.

Tue Nov 09, 2004 10:48 pm

*thinks*

Actually, I believe you can just use a text document and the command prompt to run Java. o_O

To be honest though, I have no idea how to set that up. My professor uses the whole text document/command prompt thing, but I personally think it's easier to just download JCreator like Soujiro said. It helps out a bunch when it comes down to actually compiling it (it sometimes gives useful suggestions to fix the problems), typing the code in (JCreator puts different things in different colored fonts, making it easier to read), and organization (lists methods and objects in an organized matter so you don't have to search through your code for any of that).

If you're really determined to use the whole notepad/command thing though, I can see about getting the information for you.

Tue Nov 09, 2004 10:52 pm

Java definitely needs a compiler. I don't know of any command in the command prompt that can compile a text file to Java. When a Java program is typed and compiled, it creates a *.class file and the program runs off that.

Oh, I almost forgot. You need to download the Java SDK at http://java.sun.com/ and install it before programming anything in java. It has all the class libraries and imports. You need this.

Tue Nov 09, 2004 10:55 pm

He uses the command javac [filename] to compile and java [filename] to run.

Here's a copy of the mail he sent us...

If the javac or java commands don't work in the open computer lab, do the following:

1. Put the attached file in your H: drive (your home folder)
2. Open a command window
3. if H:\> is not showing, type H: and enter
4. at the command prompt (H:\>) type setPathInDos and enter

The java and javac commands should now work.

Tue Nov 09, 2004 10:59 pm

Great. He still needs the SDK, though. Otherwise, Java would be running off of nothing.

Wed Nov 17, 2004 7:37 pm

All you need is this: http://java.sun.com/j2se/1.5.0/download-netbeans.html

NetBeans is one of the best progs.
Topic locked