Updated: March 2011
Gets the value stored in the current application domain for the specified name.
Assembly: mscorlib (in mscorlib.dll)
- Type: System.String
The name of a predefined application domain property, or the name of an application domain property you have defined.
Return ValueType: System.Object
The value of the name property, or a null reference (Nothing in Visual Basic) if the property does not exist.
Use this method to retrieve the value of an entry in an internal cache of name-data pairs that describe properties of this instance of AppDomain.
The cache automatically contains predefined system entries that are inserted when the application domain is created. You can inspect their values with the method, or the equivalent AppDomainSetup properties.
You can insert or modify your own user defined name-data pairs with the SetData method and inspect their values with the method.
The following table describes the name of each predefined system entry and its corresponding AppDomainSetup property.
Value of 'name'
"APP_LAUNCH_URL" represents the URL originally requested by the user, before any redirection. It is available only when the application has been launched with a browser such as Internet Explorer. Not all browsers provide this value.
The following code example creates a new application domain, sets a system-provided value for the domain, and adds a new value pair for the domain. The example then demonstrates how to use the method to retrieve the data from these value pairs and display them to the console.
Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98
The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.