aspose file tools*
The moose likes Servlets and the fly likes setting J2EE_HOME Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "setting J2EE_HOME" Watch "setting J2EE_HOME" New topic
Author

setting J2EE_HOME

Sree kanth
Ranch Hand

Joined: Feb 02, 2005
Posts: 53
Hi all
I am using j2ee1.4.
How do i set J2EE_HOME.
i have already set this to c:\sun\AppServer, but still when i run j2ee, it shows the error J2ee_Home is not set to the correct location.
Plz help me

Rgds
Sree


Sree
Scott Selikoff
author
Saloon Keeper

Joined: Oct 23, 2005
Posts: 3710
    
    5

Umm, your question lacks a lot of information. What do you mean when you run J2EE? Are you running a J2EE server? If so, this information needs to be set on the server.

Where did you set the variable? In Windows? Servers often do not read Windows Environment variables as they have their own set of environment variables.

Please add more details about where you are setting this as well as how you are running your J2EE app.


My Blog: Down Home Country Coding with Scott Selikoff
Sree kanth
Ranch Hand

Joined: Feb 02, 2005
Posts: 53
i am starting j2ee server by giving the command j2ee -verbose.
I've set the environmental variables in windows
Scott Selikoff
author
Saloon Keeper

Joined: Oct 23, 2005
Posts: 3710
    
    5

Still doesn't answer a lot but this should work- use the -D switch to pass parameters when you start j2ee since your starting from command line (whereever you are setting the verbose switch).

From the java.exe help menu, :

-D<name>=<value>

with no spaces between values and no <> such as:

-DJ2EE_HOME=C:\J2EE
Paul Bourdeaux
Ranch Hand

Joined: May 24, 2004
Posts: 783
1) What Server are you using? Is it the Sun Java System App Server? (I am guessing this because you have c:\Sun\AppServer in one of your earlier posts)

2) Please copy and paste the actual error message that you get when you try to start the server.


“Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning.” - Rich Cook
Scott Selikoff
author
Saloon Keeper

Joined: Oct 23, 2005
Posts: 3710
    
    5

Oh and I forgot to mention, 'verbose' has nothing to do with variables, it has to do with what information is outputted to the command line screen.
 
 
subject: setting J2EE_HOME