Custom RadFilterDataFieldEditor

2 posts, 0 answers
  1. Neil
    Neil avatar
    1 posts
    Member since:
    Sep 2012

    Posted 19 Sep 2012 Link to this post

    Hi there,

    I was wondering if it is possible to create a Custom RadFilterDataFieldEditor that would allow you to just enter a number, like say -10 or 15 and that would work like a datediff function in sql.  So it would filter on a particluar date field where that date value is between today, and -10 days say.

    I want to know if it exists, and if not, is it possible?


    Thanks in advance!
    Neil
  2. Tsvetina
    Admin
    Tsvetina avatar
    1876 posts

    Posted 24 Sep 2012 Link to this post

    Hi Neil,

    You can take as basis the last custom editor in the Custom Field Editors demo:
    http://demos.telerik.com/aspnet-ajax/filter/examples/customeditors/defaultcs.aspx

    Use it to set up a custom field editor that uses two controls. Then, in the ExtractValues method, where you actually pass the values for filtering. get your numeric values, do the needed calculation and return the two DateTime values.

    Greetings,
    Tsvetina
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top