week views
hello,
is this possible to:
1. define days of week which belong to working week in built-in "Work Week" view ?
2. change grid layout in built-in (full) "Week" view in such a way that saturday and sunday will be displayed separately ?
if yes, please tell me how.
best regards,
Adam
SIGN IN To post a reply.
3 Replies
MG
Mohanraj Gunasekaran
Syncfusion Team
January 9, 2018 12:48 PM UTC
Hi Adam,
Thanks for using Syncfusion product.
|
Query |
Solution |
|
define days of week which belong to working week in built-in "Work Week" view ? |
In order to add the Saturday and Sunday in WorkWeek view or define the custom days in this view, you can use the CustomWeek view type in ScheduleControl. By this schedule type, you can add the needed days using SelectedDates property. Please refer to the below code example,
Code example
this.scheduleControl1.ScheduleType = ScheduleViewType.CustomWeek;
//Clear the default dates
this.scheduleControl1.Calendar.SelectedDates.Clear();
this.scheduleControl1.Calendar.SelectedDates.AddRange(this.GetWeekDays());
//To reflect the changes in ScheduleControl.
this.scheduleControl1.GetScheduleHost().SetDataToDayPanels();
private DateTime[] GetWeekDays()
{
int count = 7;//No of days in week.
DateTime[] dates = new DateTime[7];
DateTime theDate = this.scheduleControl1.GetScheduleHost().Calendar.DateValue;
while (theDate.DayOfWeek != this.scheduleControl1.Appearance.NavigationCalendarStartDayOfWeek)
{
theDate = theDate.AddDays(-1);
}
this.scheduleControl1.GetScheduleHost().Calendar.SelectedDates.Clear();
for (int i = 0; i < count; i++)
{
dates[i] = theDate;
theDate = theDate.AddDays(1);
}
return dates;
} |
|
change grid layout in built-in (full) "Week" view in such a way that saturday and sunday will be displayed separately ? |
Sample link: ScheduleControl
Please let us know if you have any concerns.
Regards,
Mohanraj G
AM
amsm
January 9, 2018 01:45 PM UTC
thank You for answer to my first question.



I understand that You meant that built-in "Work Week" view can't be changed but instead I can create my custom view, right ?
what about my second question?
I would like to know is there any way to change built-in default full week view:

... in some way like in month view by setting Appearance.MonthShowFullWeek = true, from this:

... to this view:

MG
Mohanraj Gunasekaran
Syncfusion Team
January 10, 2018 03:07 PM UTC
Hi Adam,
Sorry for the inconvenience caused.
Now, we can understand your scenario. In our ScheduleControl architecture, Week view does not have the support to show the full week with creating the separate days for Saturday and Sunday.
Please let us know if you have any concerns.
Regards,
Mohanraj G
SIGN IN To post a reply.
- 3 Replies
- 2 Participants
-
AM amsm
- Jan 8, 2018 01:59 PM UTC
- Jan 10, 2018 03:07 PM UTC