Input DateRange: Promise-based custom date range?

Posted by: matt_baker on 11 June 2021, 6:40 am EST

  • Posted 11 June 2021, 6:40 am EST

    I have a project that requires a date range input with some preset custom ranges (this week, next week, etc), and also a custom range that requires a call to the server (to get the longest free-time date range for scheduling, for example), that returns a range that the inout should then use.

    Can this easily be implemented? Right now I’m using a controlTemplate button to perform this action, but I’d much rather have it in the list of preset ranges to avoid user confusion.

  • Posted 14 June 2021, 11:23 pm EST

    Hi Matt,

    Yes, this is possible. To achieve this, simply add predefined with any date range. Now, you can handle the mousedown event on the drop-down calendar and when a server range is clicked, call the server to fetch the date and set the range accordingly.

    You may refer to the sample attached for reference.

    Regards,

    Ashwin

    server range.zip

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels