Thread: 'javac' is not recognized as an internal or external command, operable program or bat

Results 1 to 9 of 9
  1. #1 'javac' is not recognized as an internal or external command, operable program or bat 
    Registered Member
    Join Date
    Sep 2020
    Posts
    9
    Thanks given
    0
    Thanks received
    0
    Rep Power
    0
    hi, when i try and compile it says
    'javac' is not recognized as an internal or external command,
    operable program or batch file.
    Press any key to continue . . .

    does anybody know how to fix this?:O
    Reply With Quote  
     

  2. #2  
    Registered Member

    Join Date
    Feb 2010
    Posts
    3,187
    Thanks given
    1,124
    Thanks received
    834
    Discord
    View profile
    Rep Power
    1514
    Yeah set your PATH variable to point to the jdk and logout. The operating system doesn't automatically know where the binaries for the jdk are so you have to tell it.
    Reply With Quote  
     

  3. #3  
    Registered Member
    Join Date
    Sep 2020
    Posts
    9
    Thanks given
    0
    Thanks received
    0
    Rep Power
    0
    Quote Originally Posted by Fire Cape View Post
    Yeah set your PATH variable to point to the jdk and logout. The operating system doesn't automatically know where the binaries for the jdk are so you have to tell it.
    ty for replying, ngl im new to java and just trying to code for fun so i dont really know what that means lol ive tried some things and it now says this -

    Compiling...
    Unrecognized option: -d
    Error: Could not create the Java Virtual Machine.
    Error: A fatal exception has occurred. Program will exit.
    Finished.
    Press any key to continue . . .


    no clue what that means my compiler is this -
    @[Only registered and activated users can see links. ] off
    echo Compiling...
    "C:/Program files/Java/jdk1.7.0_80/bin/java.exe" -cp lib/*; -d bin -sourcepath src src/*.java @[Only registered and activated users can see links. ] Finished.
    pause

    any help would be appreciated
    Reply With Quote  
     

  4. #4  
    Registered Member

    Join Date
    Feb 2010
    Posts
    3,187
    Thanks given
    1,124
    Thanks received
    834
    Discord
    View profile
    Rep Power
    1514
    Quote Originally Posted by newguyhere9183 View Post
    ty for replying, ngl im new to java and just trying to code for fun so i dont really know what that means lol ive tried some things and it now says this -

    Compiling...
    Unrecognized option: -d
    Error: Could not create the Java Virtual Machine.
    Error: A fatal exception has occurred. Program will exit.
    Finished.
    Press any key to continue . . .


    no clue what that means my compiler is this -
    @[Only registered and activated users can see links. ] off
    echo Compiling...
    "C:/Program files/Java/jdk1.7.0_80/bin/java.exe" -cp lib/*; -d bin -sourcepath src src/*.java @[Only registered and activated users can see links. ] Finished.
    pause

    any help would be appreciated
    If you go to C:/Program Files/Java/ do you have a folder called jdk and what version is it if so?
    Reply With Quote  
     

  5. #5  
    Registered Member
    Join Date
    Sep 2020
    Posts
    9
    Thanks given
    0
    Thanks received
    0
    Rep Power
    0
    Quote Originally Posted by Fire Cape View Post
    If you go to C:/Program Files/Java/ do you have a folder called jdk and what version is it if so?

    here it is - [Only registered and activated users can see links. ]
    Reply With Quote  
     

  6. #6  
    Registered Member

    Join Date
    Feb 2010
    Posts
    3,187
    Thanks given
    1,124
    Thanks received
    834
    Discord
    View profile
    Rep Power
    1514
    Quote Originally Posted by newguyhere9183 View Post
    here it is - [Only registered and activated users can see links. ]
    Oh in your compiler change java to javac for a start
    Reply With Quote  
     

  7. #7  
    Registered Member
    Join Date
    Sep 2020
    Posts
    9
    Thanks given
    0
    Thanks received
    0
    Rep Power
    0
    Quote Originally Posted by Fire Cape View Post
    Oh in your compiler change java to javac for a start

    thanks for your help ive fixed it!
    Reply With Quote  
     

  8. #8  
    Registered Member

    Join Date
    Feb 2010
    Posts
    3,187
    Thanks given
    1,124
    Thanks received
    834
    Discord
    View profile
    Rep Power
    1514
    Quote Originally Posted by newguyhere9183 View Post
    thanks for your help ive fixed it!
    No problem give us a shout if you need anything else.
    Reply With Quote  
     

  9. #9  
    Registered Member
    Join Date
    Nov 2012
    Posts
    523
    Thanks given
    12
    Thanks received
    49
    Discord
    View profile
    Rep Power
    26
    Id recommend using eclipse, helps alot to learn and guides you if you make errors.
    Reply With Quote  
     


Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Similar Threads

  1. Replies: 2
    Last Post: 06-15-2013, 02:43 AM
  2. Replies: 1
    Last Post: 12-09-2011, 10:06 PM
  3. Replies: 6
    Last Post: 08-12-2011, 03:41 AM
  4. Replies: 12
    Last Post: 10-31-2010, 10:22 PM
  5. Replies: 10
    Last Post: 05-31-2009, 01:42 PM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •