Hi,
When using the DateTimePicker control, I can set the Locale of the control, but this does use the FirstDayOfWeek value of the Locale.
Please find the code below :
--------
@using Syncfusion.Blazor.Calendars
<div class="control-section">
<div class="control_wrapper">
<div>Locale: @(System.Globalization.CultureInfo.CurrentUICulture.ToString())</div>
<div>First day of week: @(System.Globalization.CultureInfo.CurrentUICulture.DateTimeFormat.FirstDayOfWeek)</div>
<SfDatePicker TValue="DateTime"
Value="@CurrentValue"
CssClass="@CssClassCorrected"
Locale="@System.Globalization.CultureInfo.CurrentUICulture.ToString()" />
</div>
</div>
@code{
private DateTime CurrentValue = DateTime.Today;
private string CssClassCorrected = "";
protected override void OnInitialized()
{
base.OnInitialized();
System.Threading.Thread.CurrentThread.CurrentUICulture = System.Globalization.CultureInfo.GetCultureInfo("nl-BE");
}
}
--------
Output:
For the Dutch locale, the first day of the week is Monday, but it is displaying Sunday (Zo) as the first day.
Best regards,
Mike