HttpContext.GetConfig(String) Metod

Definition

Varning

The recommended alternative is System.Web.HttpContext.GetSection in System.Web.dll. http://go.microsoft.com/fwlink/?linkid=14202

Returnerar begärd konfigurationsinformation för den aktuella HTTP-begäran.

public:
 System::Object ^ GetConfig(System::String ^ name);
public object GetConfig(string name);
[System.Obsolete("The recommended alternative is System.Web.HttpContext.GetSection in System.Web.dll. http://go.microsoft.com/fwlink/?linkid=14202")]
public object GetConfig(string name);
member this.GetConfig : string -> obj
[<System.Obsolete("The recommended alternative is System.Web.HttpContext.GetSection in System.Web.dll. http://go.microsoft.com/fwlink/?linkid=14202")>]
member this.GetConfig : string -> obj
Public Function GetConfig (name As String) As Object

Parametrar

name
String

Konfigurationstaggen för vilken information begärs.

Returer

Angivet ConfigurationSection, null om avsnittet inte finns eller ett internt objekt om avsnittet inte är tillgängligt vid körning. (Omvandla det returnerade objektet till lämplig konfigurationstyp före användning.)

Attribut

Kommentarer

Metoden GetConfig är inaktuell. GetSection Använd metoden för att hämta konfigurationsinformation för den aktuella HTTP-begäran.

Gäller för

Se även