Editare

Partajați prin


QueryableFilterRepeater.ItemTemplate Property

Definition

Gets or sets the controls that populate the QueryableFilterRepeater class.

public:
 virtual property System::Web::UI::ITemplate ^ ItemTemplate { System::Web::UI::ITemplate ^ get(); void set(System::Web::UI::ITemplate ^ value); };
[System.ComponentModel.Browsable(false)]
[System.Web.UI.PersistenceMode(System.Web.UI.PersistenceMode.InnerProperty)]
[System.Web.UI.TemplateContainer(typeof(System.Web.UI.INamingContainer))]
public virtual System.Web.UI.ITemplate ItemTemplate { get; set; }
[<System.ComponentModel.Browsable(false)>]
[<System.Web.UI.PersistenceMode(System.Web.UI.PersistenceMode.InnerProperty)>]
[<System.Web.UI.TemplateContainer(typeof(System.Web.UI.INamingContainer))>]
member this.ItemTemplate : System.Web.UI.ITemplate with get, set
Public Overridable Property ItemTemplate As ITemplate

Property Value

An object that defines how items in the QueryableFilterRepeater control are displayed.

Attributes

Examples

The following example shows how to set the QueryableFilterRepeater control's ItemTemplate property so that it contains DynamicFilter controls to create the UI for each supported column type.


<!-- Set the QueryableFilterRepeater control attributes. --> 
    <asp:QueryableFilterRepeater runat="server" ID="FilterRepeaterID">
        <ItemTemplate>
            <asp:Label ID="Label1" runat="server" Text='<%# Eval("DisplayName") %>' />
            <asp:DynamicFilter runat="server" ID="DynamicFilter" 
                OnFilterChanged="OnFilterSelectionChanged"  /><br />
        </ItemTemplate>
    </asp:QueryableFilterRepeater>
<!-- Set the QueryableFilterRepeater control attributes. -->             
<asp:QueryableFilterRepeater runat="server" ID="FilterRepeaterID">
    <ItemTemplate>
        <asp:Label ID="Label1" runat="server" Text='<%# Eval("DisplayName") %>' />
        <asp:DynamicFilter runat="server" ID="DynamicFilter" 
            OnFilterChanged="OnFilterSelectionChanged" /><br />
    </ItemTemplate>
</asp:QueryableFilterRepeater>

Remarks

The ItemTemplate property defines the behavior that is used to populate the QueryableFilterRepeater control with child controls. The child controls represent the inline templates that are defined on the page.

Applies to