Skip to Main Content

New to Java

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Java( eclipse) and Environment Variables

807601Feb 28 2008 — edited Feb 28 2008
Hello,

In my Windows XP variables I have one that I want to use in a Java application.
But when I run the application this variable is not found.
I'm using Eclipse as dev IDE.
What I should do to import this environment variable to my project?

Example:
#############################################
Win32 global variable--> Test_File= "D:\Test_File\"
#######################################################
public static final String testFile = System.getProperty("Test_File");

But after this instruction testFile string is NULL. In command line, after SET command this variable is ok!!


Thanks
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 27 2008
Added on Feb 28 2008
1 comment
166 views