dateFormat property
Formats the date text in the view header view of SfCalendar time slot views.
Defaults to EE
.
See also:
- timeTextStyle, which is the text style for the time text in the timeslot views of calendar.
- dayFormat, which is the format for the day text in view header view of the timeslot views in calendar.
- ViewHeaderStyle, which is used to customize the view header view of the calendar.
- Knowledge base: How to format the view header day and date format
Widget build(BuildContext context) {
return Container(
child: SfCalendar(
view: CalendarView.workWeek,
timeSlotViewSettings: TimeSlotViewSettings(
startHour: 10,
endHour: 20,
nonWorkingDays: <int>[
DateTime.saturday,
DateTime.sunday,
DateTime.friday
],
timeInterval: Duration(minutes: 120),
timeIntervalHeight: 80,
timeFormat: 'h:mm',
dateFormat: 'd',
dayFormat: 'EEE',
timeRulerSize: 70),
),
);
}
Implementation
final String dateFormat;