locked
Telerik RadGrid Filter RRS feed

  • Question

  • User-1064997982 posted

    Dear all,

    I have a radgrid table currently, and one of the columns contain a binary value 0 and 1. I'm trying to create an external checkbox to allow me to alter the radgrid so that it displays only data with value 0 when checked and display 1 when unchecked. I've been googling but not sure about the procedure behind it. Can anyone shed some light on it or suggest any reading materials? Much appreicated

    Warm Regards,

    Faat99

    Friday, February 14, 2014 11:31 AM

Answers

  • User-933407369 posted

    hi,

    I would suggest you set the EventHandler for the ItemDataBound event in the aspx and try to access the GridDataItem in the ItemDataBound event as shown below.
    ASPX:

      <telerik:radgrid id="RadGrid1" runat="server" OnItemDataBound="RadGrid1_ItemDataBound" > 

    CS:

      protected void RadGrid1_ItemDataBound(object sender, GridItemEventArgs e) 
        { 
            if (e.Item is GridDataItem) 
            { 
                GridDataItem item = (GridDataItem)e.Item; 
                //add your logic and codes: if ... else ...
            } 
       } 

    I suggest that you can consult your issue on Telerik forum: http://demos.telerik.com/aspnet-ajax/filter/examples/integration/defaultcs.aspx?product=filter for better solution and support. Experts there will further research this issue and provide you better support.

    Thank you for your understanding.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Sunday, February 16, 2014 10:14 PM