Defines the first day of the week shown in a calendar.
Namespace: Softelvdm.SftDateNET
Assembly: Softelvdm.SftDateNET
public enum FirstDayOfWeekEnum;
Public Enum FirstDayOfWeekEnum
| Name | Description |
|---|---|
| Default | The first day of the week defined by the culture. |
| Sunday | Sunday. |
| Monday | Monday. |
| Tuesday | Tuesday. |
| Wednesday | Wednesday. |
| Thursday | Thursday. |
| Friday | Friday. |
| Saturday | Saturday. |
Defines the first day of the week shown in a calendar.
"Persian (Iran), Persian calendar",
});
comboCulture.SelectedIndex = 0;
FillCombo(comboDarkMode, typeof(DarkModeEnum), sftCalendar1.DarkMode);
FillCombo(comboHighContrast, typeof(HighContrastModeEnum), sftCalendar1.HighContrastMode);
FillCombo(comboButtons, typeof(FieldButtonsEnum), sftDate1.Buttons);
comboWeekNumbers.Items.AddRange(new object[] { "None", "Culture rule", "ISO 8601" });
comboWeekNumbers.SelectedIndex = 0;
FillCombo(comboFirstDay, typeof(FirstDayOfWeekEnum), sftCalendar1.Calendar.FirstDayOfWeek);
ShowSelection();
}
private void FillCombo(ComboBox combo, Type enumType, object current) {
foreach (object value in Enum.GetValues(enumType))
combo.Items.Add(value);
combo.SelectedItem = current;
"Thai (Thailand), Buddhist calendar",
"Persian (Iran), Persian calendar"})
ComboCulture.SelectedIndex = 0
FillCombo(ComboDarkMode, GetType(DarkModeEnum), SftCalendar1.DarkMode)
FillCombo(ComboHighContrast, GetType(HighContrastModeEnum), SftCalendar1.HighContrastMode)
FillCombo(ComboButtons, GetType(FieldButtonsEnum), SftDate1.Buttons)
ComboWeekNumbers.Items.AddRange(New Object() {"None", "Culture rule", "ISO 8601"})
ComboWeekNumbers.SelectedIndex = 0
FillCombo(ComboFirstDay, GetType(FirstDayOfWeekEnum), SftCalendar1.Calendar.FirstDayOfWeek)
ShowSelection()
End Sub
Private Sub FillCombo(ByVal combo As ComboBox, ByVal enumType As Type, ByVal current As Object)
For Each value As Object In [Enum].GetValues(enumType)
combo.Items.Add(value)
NextSee Also Classes | SftDate/NET 3.0