MenuAdapter.Control Property

Definition

Retrieves a strongly typed reference to the Menu control associated with this MenuAdapter object.

C#
protected System.Web.UI.WebControls.Menu Control { get; }

Property Value

The Menu control associated with the current MenuAdapter object.

Examples

The following code example demonstrates how to use the Control property to retrieve the Menu control of the parent class. This code example is part of a larger example provided for the MenuAdapter class.

C#
protected new System.Web.UI.WebControls.Menu Control
{
    get
    {
        return (System.Web.UI.WebControls.Menu)base.Control;
    }
}

Remarks

The Control property provides a way to reference the adapter's corresponding control. When an adapter is associated with a particular control, the .NET Framework will call the life-cycle methods of the adapter in place of or in addition to the life-cycle methods of the control.

Applies to

Ürün Sürümler
.NET Framework 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1

See also