Error with java programs after installing apache tomcat

Discussion in 'Java' started by Evrim, Mar 6, 2007.

  1. Evrim

    Evrim Guest

    Hello everybody


    I am using Win XP , JDK 6 . The environment variables are set as : PATH
    :C:\ProgramFiles\Java\jdk1.6.0\bin and CLASSPATH : . (Dot).

    I have recently installed tomcat 6 - I used the Windows Service installer -
    apache.tomcat.6.0.10.exe . I have not added any environment variables after
    installing tomcat, as I tested http://localhost:8080 and I got the tomcat
    welcome page.


    Now I face problem whenever I want to run any java programs, I get error
    message :

    Exception in thread "main" java.lang.UnsupportedClassVersionError:
    Tutorial05 (Unsupported major.minor version 50.0)


    Before installing tomcat I did not have any problems running my java
    programs.

    Please help me....


    Thank you so much .
     
    Evrim, Mar 6, 2007
    #1
    1. Advertising

  2. Evrim

    Chris Uppal Guest

    Evrim wrote:

    > I am using Win XP , JDK 6 . The environment variables are set as :
    > PATH
    > > C:\ProgramFiles\Java\jdk1.6.0\bin and CLASSPATH : . (Dot).


    > Exception in thread "main" java.lang.UnsupportedClassVersionError:
    > Tutorial05 (Unsupported major.minor version 50.0)


    The problem is that Tomcat isn't being run in the 1.6 JVM, but you are asking
    it to load classfiles compiled with a 1.6 JDK.

    I don't know anything much about running Tomcat as a service, but I'd guess
    that the %Path% you've set is wrong, or that it's not being picked by the
    "user" who the service runs as (remember that Windows has two %Path%s), or that
    there are some missing startup options to the Tomcat service.

    Maybe it's because:
    C:\ProgramFiles\Java\jdk1.6.0\bin
    which looks wrong, shouldn't it be:
    C:\ProgramFiles\Java\jdk1.6.0\jre\bin
    ?

    -- chris
     
    Chris Uppal, Mar 7, 2007
    #2
    1. Advertising

  3. Evrim

    Lew Guest

    Chris Uppal wrote:
    > Maybe it's because:
    > C:\ProgramFiles\Java\jdk1.6.0\bin
    > which looks wrong, shouldn't it be:
    > C:\ProgramFiles\Java\jdk1.6.0\jre\bin
    > ?


    There are Java executables in the JDK bin also.

    -- Lew
     
    Lew, Mar 7, 2007
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Christos Gravvanis
    Replies:
    0
    Views:
    2,062
    Christos Gravvanis
    Jul 7, 2004
  2. rhimbo
    Replies:
    1
    Views:
    1,653
    rhimbo
    Jan 21, 2005
  3. twins
    Replies:
    1
    Views:
    5,903
  4. Marcin Cenkier
    Replies:
    1
    Views:
    5,459
    Marcin Cenkier
    Apr 12, 2006
  5. Andi
    Replies:
    5
    Views:
    1,347
Loading...

Share This Page