NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

AppDomainSelector Class

Indicates the location of the configuration file for the current AppDomain.

Object
   Selector
      Internal.UrlSelectorBase
         FileSelector
            AppDomainSelector

[Visual Basic]
Public Class AppDomainSelector
   Inherits FileSelector
[C#]
public class AppDomainSelector : FileSelector
[C++]
public __gc class AppDomainSelector : public FileSelector
[JScript]
public class AppDomainSelector extends FileSelector

Remarks

Instead of directly specifying a file location, applications can read from their own configuration file by using the AppDomainSelector instead of a FileSelector. The AppDomainSelector retrieves the location of the configuration file from the currently running application domain:

Tip   The AppDomainSelector.Argument method retrieves the file path to the application configuration file.

Requirements

Namespace: System.Configuration

Assembly: System.Configuration.dll

Example [C#]

[C#]

[C#]
using System.Configuration;
using System.Configuration.Core;

IConfigCollection bindings = ConfigManager.Get("BindingPolicy", new AppDomainSelector());
foreach (bindingredir in bindings) {
  Console.WriteLine(bindingredir.Name+": "+bindingredir.Version);
}

See Also

AppDomainSelector Members | System.Configuration Namespace