Results 1 to 5 of 5
Like Tree1Likes
  • 1 Post By pbrockway2

Thread: Javac not recognize on cmd prompt

  1. #1
    Gerard is offline Member
    Join Date
    Jan 2012
    Posts
    13
    Rep Power
    0

    Default Javac not recognize on cmd prompt

    Please help this newbie.

    I am running vista hp 32 bit. I am starting to use Java and as instructed in the text book checked on cmd to see version. I typed in java -
    version and it was recognize, I typed in Javac -version and got this javac is not recognized as an internal or external command. operable program or batch file. I have been told to change path in environment profiles but I do not know to what.

    Gerard http://www.java-forums.org/images/smilies/skype/(-.gif

  2. #2
    Eranga's Avatar
    Eranga is offline Moderator
    Join Date
    Jul 2007
    Location
    Colombo, Sri Lanka
    Posts
    11,372
    Blog Entries
    1
    Rep Power
    20

    Default Re: Javac not recognize on cmd prompt

    Did you set the class path? You haven't and that is why you get that error.

    You can do it in two ways, either in temporary with the command prompt for a session or permanently using the system environment variables.

  3. #3
    Gerard is offline Member
    Join Date
    Jan 2012
    Posts
    13
    Rep Power
    0

    Default Re: Javac not recognize on cmd prompt

    Dear Eranga

    Thank you for your reply. I can find the paths but I am not sure what to put in/add in to them.

    Gerard.

  4. #4
    pbrockway2 is offline Moderator
    Join Date
    Feb 2009
    Location
    New Zealand
    Posts
    4,565
    Rep Power
    12

    Default Re: Javac not recognize on cmd prompt

    javac is not recognized as an internal or external command
    Your problem is the first one in the list given on the Common Problems page of Oracle's Tutorial. They give a link to instructions for changing the path.

    What you add to your existing path is the location of the jdk's bin directory.
    Eranga likes this.

  5. #5
    Eranga's Avatar
    Eranga is offline Moderator
    Join Date
    Jul 2007
    Location
    Colombo, Sri Lanka
    Posts
    11,372
    Blog Entries
    1
    Rep Power
    20

Similar Threads

  1. Does not recognize drawImage method...
    By Koba in forum New To Java
    Replies: 13
    Last Post: 11-21-2011, 04:06 AM
  2. Compiles and runs but won't recognize password
    By fable13 in forum New To Java
    Replies: 3
    Last Post: 07-04-2011, 10:23 PM
  3. Recognize shapes from pictures
    By acole5 in forum New To Java
    Replies: 9
    Last Post: 06-20-2011, 08:14 PM
  4. Recognize HDD, CD/ROM, DVD/ROM drives
    By xmikul28 in forum Advanced Java
    Replies: 3
    Last Post: 08-25-2009, 01:27 PM
  5. Replies: 0
    Last Post: 07-30-2008, 11:25 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •