Results 1 to 2 of 2

Thread: Compile Error for Java Program

  1. #1
    Junior Member
    Join Date
    Dec 2010
    Answers
    1

    Compile Error for Java Program

    Whenever I try to compile a program. It shows this

    javac sam.java
    javac: file not found: sam.java
    Usage: javac
    use -help for a list of possible options


  2. #2
    Junior Member
    Join Date
    Mar 2010
    Answers
    22

    Re: Compile Error for Java Program

    Hi,

    Kindly check the path of your java program.
    It seems you have not mentioned file path correctly.
    For example if you open the cmd prompt you can see the path like this
    C:\Documents and Settings\ramsri>
    If your java program in your d:java program
    you have to change the cmd prompt accordingly
    So it will be like this
    d:\java program>
    After that give javac your_ProgramName.java
    after compilation complete give java your_ProgramName
    Surely it will work

    Regards,
    ramsri4ever


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
About us
Applying for a job can be a stressful and frustrating experience, especially for someone who has never done it before. Considering that you are competing for the position with a at least a dozen other applicants, it is imperative that you thoroughly prepare for the job interview, in order to stand a good chance of getting hired. That's where GeekInterview can help.
Interact