• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 259
  • Last Modified:

Running a JAVA program

Hi. I have Downloaded all the necesarry JAVA files I need. the SDK one I needed I downloaded. Now, (since I'm learning JAVA in school) I created a ".java" file but it doesn't execute using javac.exe or java.exe through the command prompt. I know this is probably been discussed on the homepage, But all I want to know is what I have to do (since I have the necesarry files) to compile and run a java programs. a step by step procedure would be helpful. Thanks.

Ryan
0
ryan423
Asked:
ryan423
  • 4
  • 2
  • 2
  • +1
1 Solution
 
zzynxSoftware engineerCommented:
0
 
expertmbCommented:
to compile
C:\myprogramdir\javac fileName.java
to run
java fileName
0
 
expertmbCommented:
just check
@ the prompt do
C:\javac
0
Cloud Class® Course: CompTIA Cloud+

The CompTIA Cloud+ Basic training course will teach you about cloud concepts and models, data storage, networking, and network infrastructure.

 
zzynxSoftware engineerCommented:
All possible problems you could have with the classpath are described in the link I posted
0
 
ryan423Author Commented:
i'll check out the link thanks. would it be a permanent solution or would i have to do it everytime?
0
 
MindbenderCommented:
This is not an answer but advice.

You should consider downloading NetBeans from www.netbeans.org, or if you don't like IDE's, at least something like TextPad from www.textpad.com that can call the compiler for you. Especially earlier on in your learning career, NetBeans will be extremely useful for managing packages and error tracing. You have to pay for textpad, but NetBeans is 100% free.

0
 
zzynxSoftware engineerCommented:
>> would it be a permanent solution or would i have to do it everytime?
You have both options available
0
 
ryan423Author Commented:
All I had to do was set the path variable to something like "C:\j2sdk1.4.2_06\bin". Now it's permanent. Thanks a many zzynx.
0
 
zzynxSoftware engineerCommented:
Thanks
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

  • 4
  • 2
  • 2
  • +1
Tackle projects and never again get stuck behind a technical roadblock.
Join Now