Java Forums

Main Menu
Home
Today's Posts
FAQ
Search
Contact Us

Java Network
Java Tips
Java Tips Blog

Sponsored Links





Welcome to the Java Forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community, you will:

  • have access to post topics
  • communicate privately with other members (PM)
  • not see advertisements between posts
  • have the possibility to earn one of our surprises if you are an active member
  • access many other special features that will be introduced later.

Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 05-11-2008, 07:23 PM
Member
 
Join Date: May 2008
Posts: 1
waelhelbawi is on a distinguished road
Trouble compiling code
Hey guys,

I began learning Java a few days ago and until now its been a blast. At first, I tried writing my code using notepad and then compiling it using the command prompt in windows. Unfortunately, this method gave me errors. Because of this, I switched to an IDE (integrated development environment) named Eclipse. The application is awesome but I still prefer to learn how to compile using the old-fashion way
Can anyone tell me the proper steps to compiling my code using the command prompt?

P.S.: I've already downloaded the JDK Update 6.
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 05-12-2008, 05:25 AM
Eranga's Avatar
Moderator
 
Join Date: Jul 2007
Location: Colombo, Sri Lanka
Posts: 2,338
Eranga has a spectacular aura aboutEranga has a spectacular aura about
Send a message via Yahoo to Eranga
You have to set the class path for working folder. Otherwise you can't compile it.

Here is the simple way to do it.

Say your working folder is D:\JavaTest and the JDK installation folder is C:\Java\jdk1.6.0_05

Open the command prompt and change the working path to D:\JavaTest Then type this,

Code:
D:\JavaTest\>path=c:\Java\jdk1.6.0_05\bin\
Then type javac there. You get the possible options with Java, if you do it correctly.

But in this way, each time you start work on Java, have to repeat. If you how to change the AUTOEXEC.BAT file, no need to repeat this.
__________________
Use an appropriate Subject. "Help, urgent!" isn't one.
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

Has someone helped you? Then you can
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
their helpful post.

Want to make your IDE the best?
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
compiling trouble capacitator CLDC and MIDP 4 06-10-2008 11:12 PM
Compile Trouble adelgado0723 New To Java 5 04-21-2008 03:02 AM
Compiling and running code in runtime tim New To Java 4 01-27-2008 07:58 PM
Having trouble with array ice22 New To Java 3 11-13-2007 04:06 AM
JTree trouble Alantie Vala AWT / Swing 3 08-01-2007 12:12 AM


All times are GMT +3. The time now is 12:00 AM.


VBulletin, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2006 - 2007, www.java-forums.org