Menu.DynamicItemTemplate Property

Definition

Gets or sets the template that contains the custom content to render for a dynamic menu.

C#
[System.ComponentModel.Browsable(false)]
[System.Web.UI.PersistenceMode(System.Web.UI.PersistenceMode.InnerProperty)]
[System.Web.UI.TemplateContainer(typeof(System.Web.UI.WebControls.MenuItemTemplateContainer))]
public System.Web.UI.ITemplate DynamicItemTemplate { get; set; }

Property Value

A ITemplate that contains the custom content for a dynamic menu. The default value is null, which indicates that this property is not set.

Attributes

Remarks

Instead of using the built-in rendering for a dynamic menu, you can define your own look and feel for a dynamic menu item by using the DynamicItemTemplate property. To specify a custom template for a dynamic menu item, first place <DynamicItemTemplate> tags between the opening and closing tags of the Menu control. You can then list the contents of the template between the opening and closing <DynamicItemTemplate> tags. You can further control the style of a dynamic menu by using the DynamicItemFormatString property.

Applies to

Product Versions
.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