編輯

共用方式為


ConfigurationSettings.AppSettings Property

Definition

Caution

ConfigurationSettings.AppSettings has been deprecated. Use System.Configuration.ConfigurationManager.AppSettings instead.

Caution

This method is obsolete, it has been replaced by System.Configuration!System.Configuration.ConfigurationManager.AppSettings

Gets a read-only collection of the application settings from the configuration file.

public:
 static property System::Collections::Specialized::NameValueCollection ^ AppSettings { System::Collections::Specialized::NameValueCollection ^ get(); };
[System.Obsolete("ConfigurationSettings.AppSettings has been deprecated. Use System.Configuration.ConfigurationManager.AppSettings instead.")]
public static System.Collections.Specialized.NameValueCollection AppSettings { get; }
public static System.Collections.Specialized.NameValueCollection AppSettings { get; }
[System.Obsolete("This method is obsolete, it has been replaced by System.Configuration!System.Configuration.ConfigurationManager.AppSettings")]
public static System.Collections.Specialized.NameValueCollection AppSettings { get; }
[<System.Obsolete("ConfigurationSettings.AppSettings has been deprecated. Use System.Configuration.ConfigurationManager.AppSettings instead.")>]
static member AppSettings : System.Collections.Specialized.NameValueCollection
static member AppSettings : System.Collections.Specialized.NameValueCollection
[<System.Obsolete("This method is obsolete, it has been replaced by System.Configuration!System.Configuration.ConfigurationManager.AppSettings")>]
static member AppSettings : System.Collections.Specialized.NameValueCollection
Public Shared ReadOnly Property AppSettings As NameValueCollection

Property Value

A read-only collection of the application settings from the configuration file.

Attributes

Remarks

The appSettings section element of the configuration file contains a series of name/value pairs that your application can use for any purpose.

This method is obsolete and is maintained for backward compatibility. Please use the ConfigurationManager.GetSection(String) method instead.

Note

The ConfigurationSettings class provides backward compatibility only. Use the ConfigurationManager class or WebConfigurationManager class instead.

Applies to

See also