Accessing Windows System properties.
is there any way to access the system environment properties besides the subset what java supports. Say "userdomain"
Regards,
Pounraj S.,
Web Development
is there any way to access the system environment properties besides the subset what java supports. Say "userdomain"
Regards,
Pounraj S.,
by jay eckles
One way you might do this is to write a COM object that provides access to environment variables, then provide the COM object in a Java wrapper like J-Integra (I think that's the name of the software). Then your Java app can instatiate the Java wrapped COM object, call its methods, and get access to the environment variables.
I think that basically anything you come up with will break the platform independence. If that's not important to you, and you're really just developing for Windows, you might look at Visual J++ or use a Windows-specific language instead of Java, like Visual C++ or Visual Basic.
I love Java, but you have to use the right tool for the right job...
Jay Eckles
www.jayeckles.com
by pounrajs
Standard solution for this kind of problem is to pass it in when the Java application is run.
Something like:
java -Duserdomain=%userdomain% com.generationjava.WindowsApp
by pounrajs
by pounrajs
This discussion is closed to new replies.
Sort by Trending