PagesSection.MasterPageFile Propiedad

Definición

Obtiene o establece una referencia a la página maestra de la aplicación.

public:
 property System::String ^ MasterPageFile { System::String ^ get(); void set(System::String ^ value); };
[System.Configuration.ConfigurationProperty("masterPageFile", DefaultValue="")]
public string MasterPageFile { get; set; }
[<System.Configuration.ConfigurationProperty("masterPageFile", DefaultValue="")>]
member this.MasterPageFile : string with get, set
Public Property MasterPageFile As String

Valor de propiedad

Referencia a la página maestra de la aplicación.

Atributos

Ejemplos

En el ejemplo de código siguiente se muestra cómo utilizar la propiedad MasterPageFile.

// Get the current MasterPageFile property value.
Console.WriteLine(
    "Current MasterPageFile value: '{0}'",
    pagesSection.MasterPageFile);

// Set the MasterPageFile property to "MyMasterPage.ascx".
pagesSection.MasterPageFile = "MyMasterPage.ascx";
' Get the current MasterPageFile property value.
Console.WriteLine( _
    "Current MasterPageFile value: '{0}'", _
    pagesSection.MasterPageFile)

' Set the MasterPageFile property to "MyMasterPage.ascx".
pagesSection.MasterPageFile = "MyMasterPage.ascx"

Comentarios

El valor de esta propiedad puede ser una ruta de acceso relativa o absoluta.

Se aplica a

Consulte también