KeyValueConfigurationElement(String, String) Konstruktor

Definice

Inicializuje novou instanci KeyValueConfigurationElement třídy na základě zadaných parametrů.

public:
 KeyValueConfigurationElement(System::String ^ key, System::String ^ value);
public KeyValueConfigurationElement(string key, string value);
new System.Configuration.KeyValueConfigurationElement : string * string -> System.Configuration.KeyValueConfigurationElement
Public Sub New (key As String, value As String)

Parametry

key
String

Klíč KeyValueConfigurationElementklíče .

Příklady

Následující příklad kódu ukazuje použití konstruktoru KeyValueConfigurationElement . Tento příklad kódu je součástí většího příkladu KeyValueConfigurationCollection , který je k dispozici pro přehled třídy.

// Create the KeyValueConfigurationElement.
KeyValueConfigurationElement myAdminKeyVal = 
  new KeyValueConfigurationElement(
  "myAdminTool", "admin.aspx");
' Create the KeyValueConfigurationElement.
Dim myAdminKeyVal As KeyValueConfigurationElement = _
  New KeyValueConfigurationElement _
  ("myAdminTool", "admin.aspx")

Platí pro

Viz také