How to Install and Use Sun's Java SDK
Installation
- Java Development Kit from Sun use 1.6.0 SDK - 60MB EXE file
To conserve the Internet bandwidth if you are on campus (including dorms) please use
on campus location.
- Run the downloaded file. The installation will start.
Use
C:\PROGRA~1\JAVA\JDK\
as the destination location.
- After installation add Java to the system path. If you installed it to the
location mentione dabove then the addition should be
C:\PROGRA~1\JAVA\JDK\BIN
See Win2000 or WindowsXP hint. (WindowsXP has the
"Environment Variables" button located a little lower than Windows2000 in the
same dialog box.)
- Java Documentation from Sun use 1.6.0 DOC - 55MB ZIP file
To conserve the Internet bandwidth if you are on campus (including dorms) please use
on campus location.
- Open the documentation with WinZIP and extract all files to
C:\PROGRA~1\JAVA\
- Java Tutorial from Sun use 1.6.0 TUT - 25MB ZIP file
To conserve the Internet bandwidth if you are on campus (including dorms) please use
on campus location.
- Open the documentation with WinZIP and extract all files to
C:\PROGRA~1\JAVA\
How to Compile and Run Programs
- Open a console window
- Go to the folder where you saved the source file(s): cd c:\path\folder\name
- Type
javac -deprecation FileName.java
- If there are any erros, edit the program to correct the errors, save it and compile once again.
- If there are no errors - type
java FileName
to run it
.java Files and Notepad
Notepad has a "known issue" of renaming files to have .txt
extension each time "Save As" option is used. To prevent this
always start Notepad from console window by typing
notepad FileName.java
How to Access Java Library Documentation
- Create a shortcut to
C:\PROGRA~1\JAVA\DOCS\index.html
and place it on the desktop or in the Start Menu.
How to Access Java Tutorial
- Create a shortcut to
C:\PROGRA~1\JAVA\TUTORIAL\index.html
and place it on the desktop or in the Start Menu.
Java and Jobst144 Computer lab
- Open a console window
- Type
G:\JAVA\java-set
- Proceed further the same way as described in "How to Compile and Run Programs".
- This procedure must be repeated for each new console window
- Remember to use Notepad, UltraEdit or other ASCII text editor to write or modify your programs.
(Do not use MsOffice/MsWord document editor.)