NameValueConfigurationCollection.Item[String] 속성

정의

제공된 매개 변수를 NameValueConfigurationElement 기반으로 개체를 가져오거나 설정합니다.

public:
 property System::Configuration::NameValueConfigurationElement ^ default[System::String ^] { System::Configuration::NameValueConfigurationElement ^ get(System::String ^ name); void set(System::String ^ name, System::Configuration::NameValueConfigurationElement ^ value); };
public System.Configuration.NameValueConfigurationElement this[string name] { get; set; }
member this.Item(string) : System.Configuration.NameValueConfigurationElement with get, set
Default Public Property Item(name As String) As NameValueConfigurationElement

매개 변수

name
String

컬렉션에 NameValueConfigurationElement 포함된 이름입니다.

속성 값

NameValueConfigurationElement 개체입니다.

예제

다음 코드 예제에서는 속성을 사용 하는 방법을 보여 줍니다 Item[] . 이 코드 예제는 클래스에 제공된 더 큰 예제의 NameValueConfigurationCollection 일부입니다.

// Item property.
Console.WriteLine("Value of property 'enabled': {0}",
 myNameValConfigCollection["enabled"].Value);
' Item property.
Console.WriteLine("Value of property 'enabled': {0}", myNameValConfigCollection("enabled").Value)

설명

매개 변수를 Item[] 기반으로 name 개체를 NameValueConfigurationElement 가져오기 또는 설정하려면 이 속성을 사용합니다.

적용 대상