Getting Started with JVC
The two programs that you'll use to write JAVA programs are:
1)'C:\WINNT\JView.exe' used to view JAVA CLASS files. JView can only
be used to view Java Applications, use Netscape or Internet Explorer
to view applets.
2)'D:\DevStudio\SharedIDE\BIN\JVC.exe' is used to compile JAVA programs.
Before getting started you will probably want to add JVC.exe to your
current path. Windows NT has a utility for this called Pathman.exe which
can be found at "D:\NTRESKIT\Pathman.exe".
To add JVC to your current path first start a command prompt.
(Start->programs->Dos Prompt)
From the command line type:
>D:
>cd D:\NTRESKIT
>pathman /au D:\DevStudio\sharedIDE\BIN;
You'll need to logout and then log back on for the changes to take effect.
If you are intrested, you can find out more about pathman in the file
"D:\NTRESKIT\Pathman.wri".
Any text editor can be used to write your JAVA programs, but be sure
to save them in the "TXT" format or they probably won't compile correctly.
I used wordpad for this tutorial. It can be found on the start menu
under: Start->Programs->Accesories->Wordpad.
Here's the program:
//
//
// HelloWorld
//
//
public class HelloWorld
{
public static void main(String[] args){
System.out.println("Hello World!");
}
}
Save the file as HelloWorld.java, (The Z drive under your user name is a
good place)
start a new command line prompt and cd to the directory where you saved
your file. Make sure that the file name matches the name of the class and
that you use the .java extension or it will not compile.
To compile the program enter:
>jvc HelloWorld.java
Java is case sensitive so "helloworld.java" is not the same
as "HelloWorld.java".
This will produce a class file with the same name, and a .class extension.
To view the program enter:
>jview HelloWorld.class
That's all there is to it.