Enable filtering for GridButtonColumn in RadGrid

8 posts, 0 answers
  1. Gayatri
    Gayatri avatar
    10 posts
    Member since:
    Mar 2009

    Posted 20 Mar 2009 Link to this post

    Hi
        I am using Rad Grid in my application. I am adding the columns to the grid at the runtime. I have filtering enabled for all the columns except a gridbutton column . How to enable filtering and sorting for the column. Also i have set the AllowFilteringByColumn to true. Please help me out in this issue.

    Thanks
    Gayatri
  2. Shinu
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 20 Mar 2009 Link to this post

    Hi Gayathri,

    You can refer the following code library submission which explains how to implement Filtering and Sorting with GridButtonColumn.
    Filtering and sorting for GridButtonColumn

    Regards
    Shinu.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Gayatri
    Gayatri avatar
    10 posts
    Member since:
    Mar 2009

    Posted 20 Mar 2009 Link to this post

    hi

        i am unable to open the link you have provided. i got page was not found error. please help.

    thanks
    Gayatri
  5. Shinu
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 20 Mar 2009 Link to this post

    HI Gayathri,

    Here is the valid link. Plaese check out this.
    Filtering and sorting for GridButtonColumn

    Regards
    Shinu
  6. Gayatri
    Gayatri avatar
    10 posts
    Member since:
    Mar 2009

    Posted 21 Mar 2009 Link to this post

    Thanks a lot. It works...
  7. Manuel Ajoy
    Manuel Ajoy avatar
    2 posts
    Member since:
    May 2010

    Posted 20 May 2010 Link to this post

    Hello,

    I have a static grid with dynamically created columns.  I followed the recommendation in www.telerik.com/help/aspnet/grid/grdprogrammaticcreation.html under the "Create Telerik RadGrid statically, but add its structure dynamically." section to do this.

    So far, I have a working grid with several dynamically created bound columns as well as a GridButtonColumn (without Filtering and Sorting).  This grid is currently using ajax and generating successfull asynchronous postbacks on Refresh/sorting/filtering events.

    However, when I tried converting to a GridButtonColumnWithFilteringAndSorting, no asynchronous autopostback occurs even though I have the AutoPostBackOnFilter set to true. 

    Moreover, if I click on the filtering image and choose the Contains filtering function on the GridButtonColumnWithFilteringAndSorting I get a javascript error that says:

    Sys.WebForms.PageRequestManagerServerErrorException: Cannot create column with the specified type name: GridButtonColumnWithFilteringAndSorting.

    I am not really sure what my problem is so any help on this matter would be greatly appreciated.

     

    Thank you in advance,

    Manuel

  8. Manuel Ajoy
    Manuel Ajoy avatar
    2 posts
    Member since:
    May 2010

    Posted 20 May 2010 Link to this post

    Hello,

    While looking at other forums I found out that a partial solution to my problem was to set the MasterTableView's EnableColumnsViewState property to false.  I tried this and I no longer get the javascript error mentioned above.  Filtering works with the GridButtonColumnWithFilteringAndSorting if I click on the filtering image and select any of the filtering functions.

    However, one of my application requirements includes firing the filtering command (i.e.: generating an asynchronous postback) whenever the user presses the [ENTER] or [TAB] key while inside the filtering textbox.

    Is there a way to accomplish this using the GridButtonColumnWithFilteringAndSorting column?

    Manuel



  9. Prangadj
    Prangadj avatar
    174 posts
    Member since:
    Jan 2008

    Posted 21 May 2010 Link to this post

    Try to implement filtering on [Enter] press as for the textbox in command item on this sample. Same can probably be done on TAB key if you listen for the TAB keyCode inside the javascript method.

    Prangadj
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017