We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: June 24, 2019).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Change Date picker view format to Week or month.

Thread ID:

Created:

Updated:

Platform:

Replies:

143984 Apr 12,2019 11:14 AM UTC Apr 12,2019 12:46 PM UTC React - EJ 2 1
loading
Tags: DatePicker
Sonam Diwate
Asked On April 12, 2019 11:14 AM UTC

Ho do i change date picker format to week view and month view like below.

Week view

Month View



Currently I am using : format: { skeleton: 'full' } this format

Ashokkumar Balasubramanian [Syncfusion]
Replied On April 12, 2019 12:46 PM UTC

Hi Sonam, 
 
Thanks for contacting syncfusion support. 
 
Week View:  
 
Your provided image contains range between one date to another date. For this case, we suggested to use the DateRangePicker, because we can’t display more than one date range in DatePicker. Please find the below code block. 
 
<DateRangePickerComponent format={this.weekformat} endDate={this.endDate} startDate={this.startDate}></DateRangePickerComponent> 
 
 
To know more details about DateRangePicker component, please refer the below help document. 
 
 
Month View: 
 
Our DatePicker component, we have provided the format property for customize the date format displayed to user. You can use this property to achieve your requirement. Please find the below code block. 
 
constructor() { 
    super(...arguments); 
    this.dateValue = new Date(); 
    this.format = 'MMM yyyy'; 
} 
 
<DatePickerComponent format={this.format} value={this.dateValue}></DatePickerComponent> 
 
  
The above two requirements are showcased in below sample, please check it. 
 
 
Please let us know, if you have any concern on this. 
 
Regards, 
Ashokkumar B. 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon