Class CalendarBase<T>
The Calendar is a graphical user interface component that displays a Gregorian Calendar, and allows a user to select a date.
Inheritance
Inherited Members
Namespace: Syncfusion.Blazor.Calendars
Assembly: Syncfusion.Blazor.dll
Syntax
public class CalendarBase<T> : SfInputTextBase<T>
Type Parameters
Name | Description |
---|---|
T | Specifies the type of CalendarBase. |
Constructors
CalendarBase()
Declaration
public CalendarBase()
Properties
CalendarEditContext
Specifies the editcontext of the Calendar.
Declaration
protected EditContext CalendarEditContext { get; set; }
Property Value
Type |
---|
Microsoft.AspNetCore.Components.Forms.EditContext |
CalendarMode
Sets the calendar's type like Gregorian.
Declaration
public CalendarType CalendarMode { get; set; }
Property Value
Type |
---|
CalendarType |
DayHeaderFormat
Specifies the format of the day that to be displayed in the header. By default, the format is short.
Possible formats are:
- ShortSets the short format of day name (like Su ) in day header.
- NarrowSets the single character of day name (like S ) in day header.
- AbbreviatedSets the min format of day name (like Sun ) in day header.
- WideSets the long format of day name (like Sunday ) in day header.
Declaration
public DayHeaderFormats DayHeaderFormat { get; set; }
Property Value
Type |
---|
DayHeaderFormats |
Depth
Sets the maximum level of views such as a month, year, and decade in the calendar.
The depth view should be smaller than the start view to restrict its view navigation.
Declaration
public CalendarView Depth { get; set; }
Property Value
Type |
---|
CalendarView |
FirstDayOfWeek
Sets the calendar's first day of the week. By default, the first day of the week will be based on the current culture.
Declaration
public int FirstDayOfWeek { get; set; }
Property Value
Type |
---|
System.Int32 |
KeyConfigs
Customizes the key actions in the calendar.
For example, when using a German keyboard, the key actions can be customized using these shortcuts.
Declaration
public Dictionary<string, object> KeyConfigs { get; set; }
Property Value
Type |
---|
System.Collections.Generic.Dictionary<System.String, System.Object> |
Max
Gets or sets the maximum allowable date or time value.
Declaration
public virtual DateTime Max { get; set; }
Property Value
Type |
---|
System.DateTime |
Min
Specifies a minimum date that is allowed a user can select in the calendar.
Declaration
public virtual DateTime Min { get; set; }
Property Value
Type |
---|
System.DateTime |
ServerTimezoneOffset
By default, the date value will be processed based on the system time zone.
If you want to process the initial date value using the server time zone then specify the time zone value to the ServerTimezoneOffset property.
Declaration
public double ServerTimezoneOffset { get; set; }
Property Value
Type |
---|
System.Double |
ShowTodayButton
Specifies whether the today button will be displayed in the calendar.
Declaration
public bool ShowTodayButton { get; set; }
Property Value
Type |
---|
System.Boolean |
Start
Specifies the initial view of the calendar when it is opened. With the help of this property, the initial view can be changed to the year or decade view.
Declaration
public CalendarView Start { get; set; }
Property Value
Type |
---|
CalendarView |
WeekNumber
Specifies whether the week number of the year will be displayed in the calendar.
Declaration
public bool WeekNumber { get; set; }
Property Value
Type |
---|
System.Boolean |
WeekRule
Specifies the rule for defining the first week of the year.
Declaration
public CalendarWeekRule WeekRule { get; set; }
Property Value
Type |
---|
System.Globalization.CalendarWeekRule |
Methods
ChangeEvent(EventArgs, Boolean)
Triggers when the value get changed.
Declaration
protected virtual void ChangeEvent(EventArgs args, bool isSelection = false)
Parameters
Type | Name | Description |
---|---|---|
System.EventArgs | args | Specifies the System.EventArgs. |
System.Boolean | isSelection | Determines whether selection is made using the mouse or keyboard. |