Share via


ConfigurationSettings.GetConfig(String) Método

Definición

Precaución

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

Precaución

ConfigurationSettings.GetConfig has been deprecated. Use System.Configuration.ConfigurationManager.GetSection instead.

Devuelve el objeto ConfigurationSection para el nombre y la ruta de acceso de sección de configuración que se han pasado.

public:
 static System::Object ^ GetConfig(System::String ^ sectionName);
[System.Obsolete("This method is obsolete, it has been replaced by System.Configuration!System.Configuration.ConfigurationManager.GetSection")]
public static object GetConfig (string sectionName);
[System.Obsolete("ConfigurationSettings.GetConfig has been deprecated. Use System.Configuration.ConfigurationManager.GetSection instead.")]
public static object GetConfig (string sectionName);
public static object GetConfig (string sectionName);
[<System.Obsolete("This method is obsolete, it has been replaced by System.Configuration!System.Configuration.ConfigurationManager.GetSection")>]
static member GetConfig : string -> obj
[<System.Obsolete("ConfigurationSettings.GetConfig has been deprecated. Use System.Configuration.ConfigurationManager.GetSection instead.")>]
static member GetConfig : string -> obj
static member GetConfig : string -> obj
Public Shared Function GetConfig (sectionName As String) As Object

Parámetros

sectionName
String

Nombre y ruta de acceso de configuración, como "system.net/settings".

Devoluciones

Objeto ConfigurationSection correspondiente al nombre y la ruta de acceso de sección de configuración que se han pasado.

Atributos

Excepciones

No se ha podido recuperar la sección solicitada.

Comentarios

Este método está obsoleto y se mantiene para la compatibilidad con versiones anteriores. Use el ConfigurationManager.GetSection(String) método en su lugar.

Se aplica a

Consulte también