EJ2: How to customize DateRangePicker

Hi,

1) We want to set Monday as the 1st day of the week and not Sunday. Can you tell us how to do that?
2) There was a "Reset" button on EJ1. How can we display that on EJ2 calendar?

Thanks



3 Replies

PM Ponmani Murugaiyan Syncfusion Team February 25, 2020 12:18 PM UTC

Hi Support, 

Greetings from Syncfusion support. We have validated your reported query. 

Query 1: We want to set Monday as the 1st day of the week and not Sunday. Can you tell us how to do that? 

You can set any days as the first day of the week in EJ2 calendar using the API FirstDayOfWeek. Please find the code snippet below for your reference. 

[Index.cshtml] 

@Html.EJS().DateRangePicker("range").Select("OnSelect").Created("OnCreate").Open("OnOpen").FirstDayOfWeek(1).Render() 



Output: 

 

Query 2: There was a "Reset" button on EJ1. How can we display that on EJ2 calendar? 

In EJ2 DateRangePicker, there is no RESET button option to reset the values. We have customized the sample as per your requirement and while reset the popup will be refresh and get closed. Please find the sample and code snippet below. 

 
 
If you need any further assistances on this, Please get back us. 

Regards, 
Ponmani M 



SA Support Arcania February 26, 2020 10:07 AM UTC

Great,

Thanks for your help!


PM Ponmani Murugaiyan Syncfusion Team February 26, 2020 12:58 PM UTC

Hi Support, 
  
Thanks for your feedback. If you need further assistance on this, please get back us. 
  
Regards, 
Ponmani M 


Loader.
Up arrow icon