Page 2 of 2 FirstFirst 12
Results 21 to 29 of 29
  1. #21
    Norm's Avatar
    Norm is online now Moderator
    Join Date
    Jun 2008
    Location
    SW Missouri
    Posts
    17,516
    Rep Power
    25

  2. #22
    evacoppola is offline Member
    Join Date
    Jul 2010
    Posts
    3
    Rep Power
    0

    Default This is the code I appended to the field

    I am using version jdk1.6.0_21, so I appended the following exactly to the end of my PATH field.

    ;C:\Program Files\Java\jdk1.6.0_21%JAVA_HOME%\bin

    I ran a couple of exe's from the command line, and did not receive any errors.

    I also ran from the command line:

    java -version

    And I received back the correct data:
    java version "1.6.0_21"
    Java(TM) SE Runtime Environment (build 1.6.0_21-b07)
    Java HotSpot(TM) Client VM (build 17.0-b17, mixed mode, sharing)

  3. #23
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    13,560
    Blog Entries
    7
    Rep Power
    21

    Default

    Quote Originally Posted by evacoppola View Post
    I am using version jdk1.6.0_21, so I appended the following exactly to the end of my PATH field.

    ;C:\Program Files\Java\jdk1.6.0_21%JAVA_HOME%\bin

    I ran a couple of exe's from the command line, and did not receive any errors.

    I also ran from the command line:

    java -version

    And I received back the correct data:
    java version "1.6.0_21"
    Java(TM) SE Runtime Environment (build 1.6.0_21-b07)
    Java HotSpot(TM) Client VM (build 17.0-b17, mixed mode, sharing)
    What is the value of JAVA_HOME? It seems to me that you are using things two times; your path variable should contain C:\Program Files\Java\jdk1.6.0_21\bin or just %JAVA_HOME%\bin where JAVA_HOME is set to the correct value.

    kind regards,

    Jos

  4. #24
    evacoppola is offline Member
    Join Date
    Jul 2010
    Posts
    3
    Rep Power
    0

    Default setting Path variable

    ooOOHHHhhh - thankyou JosAH - I wasn't sure about it, but was trying different things because I couldn't get anyone to tell me definitively which is better.

    What do you recommend?

    If I were to use %JAVA_HOME% , where would I set the correct value - is there a global place to set it?

    I am having trouble running the compiler on a program from the command line - I have saved the program as *.java, and attempted to run:

    javac *.java , but it can't find the program. I did save the code in the Program Files\Java folder, but it still does not find it. Can you suggest what I might be missing?

  5. #25
    JosAH's Avatar
    JosAH is offline Moderator
    Join Date
    Sep 2008
    Location
    Voorschoten, the Netherlands
    Posts
    13,560
    Blog Entries
    7
    Rep Power
    21

    Default

    Quote Originally Posted by evacoppola View Post
    ooOOHHHhhh - thankyou JosAH - I wasn't sure about it, but was trying different things because I couldn't get anyone to tell me definitively which is better.

    What do you recommend?

    If I were to use %JAVA_HOME% , where would I set the correct value - is there a global place to set it?
    You set it in the same dialog box as where you set your path variable. Both are environment variables; for now I'd forget about JAVA_HOME and set the PATH variable to where your javac.exe file is stored.

    kind regards,

    Jos

  6. #26
    evacoppola is offline Member
    Join Date
    Jul 2010
    Posts
    3
    Rep Power
    0

    Default PATH variables

    Thanks JosAH , I actually figured it out after I posted the question. I prefer to use JAVA_HOME (I added the variable to the list so that I could use it). Thanks! :)

  7. #27
    Join Date
    Sep 2010
    Posts
    1
    Rep Power
    0

    Default

    Quote Originally Posted by DivyaG View Post
    hi all,

    I installed jdk1.6.0_21 version and if I try to compile a simple Hello.java file, it throws an error saying "javac is not recognised as internal or external command". I have set my path as E:\Program files\java\jdk1.6.0_21\bin; Should it be set as both user & system variables??

    Whats the mistake here?? plzzz help.
    @DIVYAG :::problem with javac

    create and set user variable JAVA_HOME = "E:\Progra~1\java\jdk1.6.0_21\"
    instead of "E:\Program files\java\jdk1.6.0_21\bin"

    also edit system variable PATH=;E:\Progra~1\java\jdk1.6.0_21\lib;

    cheers

  8. #28
    venkateshn313 is offline Member
    Join Date
    Oct 2010
    Posts
    3
    Rep Power
    0

    Default

    Quote Originally Posted by kotoko View Post
    I am unable to runthe javac command
    I get a "javac not recognized as an internal or external command"
    I searched and tried everything I found but nothing works.
    What I have so far:
    :confused: eclipse runs perfectly (but I really need to run javac for school purposes)

    :confused: my system variables:
    JAVA_HOME -> C:\Programas\Java\jdk1.6.0
    CLASSPATH -> .;%JAVA_HOME%
    Path -------> %SystemRoot%\system32;%SystemRoot%;%SystemRoot%\Sy stem32\Wbem;C:\Programas\ATI Technologies\ATI Control Panel;C:\Programas\MATLAB7\bin\win32; %PATH%; %JAVA_HOME%\\bin

    :confused: if I hava the file.java inside the directory where javac is it works perfectly

    Pleeease help!


    :confused: I'm trying to compile at D:\dei\workspace\HelloWorld\src
    i set correctly but not working..

  9. #29
    Fubarable's Avatar
    Fubarable is offline Moderator
    Join Date
    Jun 2008
    Posts
    19,316
    Blog Entries
    1
    Rep Power
    26

    Default

    If you have your own question, you'd be best to ask it in it's own thread and give more details such as how you are trying to call things and what error messages you may be getting. Locking this older thread.

Page 2 of 2 FirstFirst 12

Similar Threads

  1. Eclipse's internal Tomcat
    By vadimf in forum Eclipse
    Replies: 0
    Last Post: 02-14-2008, 09:37 AM
  2. Unable to execute command line command in java
    By LordSM in forum New To Java
    Replies: 1
    Last Post: 08-08-2007, 12:23 AM
  3. an internal error occurred during refresh
    By christina in forum Eclipse
    Replies: 1
    Last Post: 08-06-2007, 09:37 PM
  4. Replies: 4
    Last Post: 07-20-2007, 04:18 AM
  5. Description the server encountered an internal error
    By Jack in forum Enterprise JavaBeans (EJB)
    Replies: 2
    Last Post: 07-02-2007, 02:24 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
  •