This is a migrated thread and some comments may be shown as answers.

RadGrid Filter Problem

2 Answers 92 Views
Grid
This is a migrated thread and some comments may be shown as answers.
mohamed
Top achievements
Rank 1
mohamed asked on 18 Jul 2011, 05:36 AM
<telerik:GridTemplateColumn UniqueName="TempcolFormat" HeaderText="Title">
                               <ItemTemplate>
                                   <table>
                                       <tr>
                                           <td style="border: 0px;">
                                               <asp:Label ID="Label1" runat="server" Text='Title : '></asp:Label>
                                               <asp:Label ID="Lb2" Font-Bold="true" runat="server" Text='<%# Eval("title") %>'></asp:Label>
                                           </td>
                                       </tr>
                                       <tr>
                                           <td style="border: 0px;">
                                               <asp:Label ID="Lb3" runat="server" Text='<%# Eval("description") %>'></asp:Label>
                                           </td>
                                       </tr>
                                   </table>
                               </ItemTemplate>
                           </telerik:GridTemplateColumn>

I bind radgrid like that . filter's not work for't in this condition.

Thanks,
Mohamed.

2 Answers, 1 is accepted

Sort by
0
Accepted
Shinu
Top achievements
Rank 2
answered on 18 Jul 2011, 06:06 AM
Hello Mohamed,

In order to enable filtering for template column, set the DataField property of the template column to the field you want to use for filtering.

aspx:
<telerik:GridTemplateColumn UniqueName="TempcolFormat" HeaderText="Title" DataField="Title">
          <ItemTemplate>
              <table>
                   <tr>
                       <td style="border: 0px;">
                              <asp:Label ID="Label1" runat="server" Text='Title : '></asp:Label>
                              <asp:Label ID="Lb2" Font-Bold="true" runat="server" Text='<%# Eval("title") %>'></asp:Label>
                       </td>
                   </tr>

Thanks,
Shinu.
0
mohamed
Top achievements
Rank 1
answered on 18 Jul 2011, 06:20 AM
Thanks for ur reply Shinu,

One More doubt ,
How i search both fields Shinu,


Thanks,
Mohamed
Tags
Grid
Asked by
mohamed
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
mohamed
Top achievements
Rank 1
Share this question
or