This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
hello in my servlet,there is following code block: File f=new File("%JAVA_HOME%\\test.txt"); f.createNewFile(); the "JAVA_HOME" is the environment variable of my windows.after i deploy it to jboss,it threw exception.that tell me can't find the path. then i modify it as: File f=new File("%JBOSS_HOME%\\test.txt"); f.createNewFile(); the "JBOSS_HOME" is definde in its "run.bat " file. the code still don't work. who can tell me : 1 how can i use the environment variable of os or app server? 2 how and where can i set up a envrionment variable as the base dir ? thank you.