ConfigurationSection.TryGetValue(String, String) Méthode
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Tente d’obtenir la valeur de cette section sous forme de chaîne.
public:
bool TryGetValue(System::String ^ key, [Runtime::InteropServices::Out] System::String ^ % value);
public bool TryGetValue(string? key, out string? value);
member this.TryGetValue : string * string -> bool
Public Function TryGetValue (key As String, ByRef value As String) As Boolean
Paramètres
- key
- String
Clé de configuration. Si null, la valeur de la section elle-même est retournée.
- value
- String
Lorsque cette méthode est retournée, contient la valeur de la section s’il existe ; sinon, null.
Retours
true si la valeur a été trouvée ; sinon, false.