System.Web.UI.WebControls.Adapters.MenuAdapter Class

Provides the means to modify the behavior of the System.Web.UI.WebControls.Menu control for specific browsers.

See Also: MenuAdapter Members


public class MenuAdapter : WebControlAdapter, System.Web.UI.IPostBackEventHandler


A System.Web.UI.WebControls.Adapters.MenuAdapter modifies the markup or behavior of a System.Web.UI.WebControls.Menu control for a specific browser or class of browsers, or acts as a filter on some capability.

By default, the System.Web.UI.WebControls.MenuItem objects in the System.Web.UI.WebControls.Menu control are rendered as hyperlinks to accommodate menu navigation. The System.Web.UI.WebControls.Menu class maintains state by implementing the System.Web.UI.IPostBackEventHandler interface so that it can respond to and raise specific events during postback. You can extend the System.Web.UI.WebControls.Adapters.MenuAdapter class to further customize rendering or behavior of the System.Web.UI.WebControls.Menu control.

The initial request for an adapter causes the .NET Framework to search for a mapped adapter for the control, given the characteristics of the requesting browser. The System.Web.HttpBrowserCapabilities class uses browser definition files to identify the characteristics of the client browser and to map the adapter to the browser type.

For more information about adaptive rendering in ASP.NET, see Architectural Overview of Adaptive Control Behavior.


Namespace: System.Web.UI.WebControls.Adapters
Assembly: System.Web (in System.Web.dll)
Assembly Versions:
Since: .NET 2.0