The information in this article applies to:
SYMPTOMSWhen you run a Java application within the Visual J++ 6.0 integrated development environment (IDE), none of the environment variables are set. However, when you run the application from the command line using jview or wjview, variables are set as expected. Note that this also includes the CLASSPATH environment variable. CAUSEWhen you run an application within the Visual J++ 6.0 IDE, the application's environment is not inherited from the parent process and variables are empty. However, when you run it outside the Visual J++ 6.0 IDE (from the command line or otherwise), the application's environment is inherited from the parent process and environment variables have the values of the parent. RESOLUTIONYou need to programmatically set environment variables when you run the application within the Visual J++ 6.0 IDE. To work around this problem, you can start the application outside the Visual J++ 6.0 IDE (using jview) and attach to the process for debugging with access to the environment variables (please see the comments in the sample code below). STATUSThis behavior is by design. MORE INFORMATIONSteps to Reproduce BehaviorCompile and run the following code:
RESULT: From the command line, you get C:\TEMP. If you click Start or Start Without Debugging on the Debug menu in a Visual J++ 6.0 project, you get the following error message:
REFERENCESFor the latest Knowledge Base articles and other support information on Visual J++ and the SDK for Java,
please see the following pages on the Microsoft Technical Support site: http://support.microsoft.com/support/visualj/ Additional query words:
Keywords : kbide kbVJ600 kbGrpJava |
Last Reviewed: November 16, 1999 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |