You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: blazor/autocomplete/disabled-items.md
-1Lines changed: 0 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,7 +27,6 @@ The disableItem method can be used to handle dynamic changing in disable state o
27
27
28
28
| Parameter | Type | Description |
29
29
|------|------|------|
30
-
| itemHTMLLIElement | <code>HTMLLIElement</code> | It accepts the HTML Li element of the item to be removed. |
31
30
| itemValue | <code>string</code> \| <code>number</code> \| <code>boolean</code> \| <code>object</code> | It accepts the string, number, boolean and object type value of the item to be removed. |
32
31
| itemIndex | <code>number</code> | It accepts the index of the item to be removed. |
Copy file name to clipboardExpand all lines: blazor/combobox/disabled-items.md
-1Lines changed: 0 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,7 +27,6 @@ The disableItem method can be used to handle dynamic changing in disable state o
27
27
28
28
| Parameter | Type | Description |
29
29
|------|------|------|
30
-
| itemHTMLLIElement | <code>HTMLLIElement</code> | It accepts the HTML Li element of the item to be removed. |
31
30
| itemValue | <code>string</code> \| <code>number</code> \| <code>boolean</code> \| <code>object</code> | It accepts the string, number, boolean and object type value of the item to be removed. |
32
31
| itemIndex | <code>number</code> | It accepts the index of the item to be removed. |
Copy file name to clipboardExpand all lines: blazor/datepicker/date-format.md
+16-3Lines changed: 16 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,13 +9,15 @@ documentation: ug
9
9
10
10
# Date Format in Blazor DatePicker Component
11
11
12
-
The date format can be used to specify how the date value is displayed or entered in a `DatePicker` control
12
+
## Display Format
13
+
14
+
The display format can be used to specify how the date value is displayed or entered in a `DatePicker` control
13
15
14
16
The string format of the date value specifies how the date value should be represented as a string. Different countries and regions have different conventions for representing the date value in a string format. In addition to representing the date value in different string formats, it is also possible to specify the order in which the day, month, and year values appear in the string. For example, the day/month/year format could be written as `28-12-2022` or `28.12.2022`
15
17
16
18
By default, the DatePicker's format is based on the culture. You can also set the own [Custom Format](https://learn.microsoft.com/en-us/dotnet/standard/base-types/custom-date-and-time-format-strings) or [Standard Format](https://learn.microsoft.com/en-us/dotnet/standard/base-types/standard-date-and-time-format-strings) by using the [Format](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Calendars.SfDatePicker-1.html#Syncfusion_Blazor_Calendars_SfDatePicker_1_Format) property.
17
19
18
-
> Once the date format property has been defined, it will be applied consistently to all cultures, regardless of their conventions for representing the date value. In other words, the date format property serves as a standardized way of representing the date value, ensuring that it is displayed and entered consistently regardless of the culture or region in which the application is used.
20
+
> Once the display format property has been defined, it will be applied consistently to all cultures, regardless of their conventions for representing the date value. In other words, the display format property serves as a standardized way of representing the date value, ensuring that it is displayed and entered consistently regardless of the culture or region in which the application is used.
19
21
20
22
{% highlight Razor %}
21
23
@@ -24,5 +26,16 @@ By default, the DatePicker's format is based on the culture. You can also set th
24
26
{% endhighlight %}
25
27
26
28
29
+

30
+
31
+
## Input Formats
32
+
33
+
The input format can be used to specify how the date value is entered in a `DatePicker` control.
34
+
35
+
The string format of the date value specifies how the date should be represented as a string when entered by the user. When the user types the date in the input format, it will be automatically converted to the display format after pressing enter, tab key, or when the input loses focus. This enhances the user experience by allowing intuitive data entry through various custom input formats. You can also set your own [Custom Format](https://learn.microsoft.com/en-us/dotnet/standard/base-types/custom-date-and-time-format-strings) or [Standard Format](https://learn.microsoft.com/en-us/dotnet/standard/base-types/standard-date-and-time-format-strings) by using [InputFormats](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Calendars.SfDatePicker-1.html#Syncfusion_Blazor_Calendars_SfDatePicker_1_InputFormats) property.
Copy file name to clipboardExpand all lines: blazor/datetime-picker/date-time-format.md
+16-2Lines changed: 16 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,7 +8,9 @@ documentation: ug
8
8
---
9
9
# DateTime Format in Blazor DateTimePicker Component
10
10
11
-
The date and time format can be used to specify how the date and time value is displayed or entered in a `DateTimePicker` control
11
+
## Display Date and Time format
12
+
13
+
The display date and time format can be used to specify how the date and time value is displayed or entered in a `DateTimePicker` control
12
14
13
15
By default, the DateTimePicker's format is based on the culture. You can also set the own [Custom Format](https://learn.microsoft.com/en-us/dotnet/standard/base-types/custom-date-and-time-format-strings) or [Standard Format](https://learn.microsoft.com/en-us/dotnet/standard/base-types/standard-date-and-time-format-strings) by using the [Format](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Calendars.SfDatePicker-1.html#Syncfusion_Blazor_Calendars_SfDatePicker_1_Format) property.
14
16
@@ -21,4 +23,16 @@ By default, the DateTimePicker's format is based on the culture. You can also se
21
23
{% endhighlight %}
22
24
23
25
24
-

26
+

27
+
28
+
## Input Formats
29
+
30
+
The input format can be used to specify how the date and time value is entered in a `DateTimePicker` control.
31
+
32
+
The string format of the date and time value specifies how the date and time should be represented as a string when entered by the user. When the user types the date and time in the input format, it will be automatically converted to the display format after pressing enter, tab key, or when the input loses focus. This enhances the user experience by allowing intuitive data entry through various custom input formats. You can also set your own [Custom Format](https://learn.microsoft.com/en-us/dotnet/standard/base-types/custom-date-and-time-format-strings) or [Standard Format](https://learn.microsoft.com/en-us/dotnet/standard/base-types/standard-date-and-time-format-strings) by using the [InputFormats](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Calendars.SfDateTimePicker-1.html#Syncfusion_Blazor_Calendars_SfDateTimePicker_1_InputFormats) property.
Copy file name to clipboardExpand all lines: blazor/datetime-picker/date-time-range.md
+41-1Lines changed: 41 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,6 +9,8 @@ documentation: ug
9
9
10
10
# DateTime Range in Blazor Datetime Picker Component
11
11
12
+
## DateTime Restriction
13
+
12
14
DateTimePicker provides an option to select a date and time value within a specified range by using the [Min](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Calendars.SfDateTimePicker-1.html#Syncfusion_Blazor_Calendars_SfDateTimePicker_1_Min) and [Max](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Calendars.SfDateTimePicker-1.html#Syncfusion_Blazor_Calendars_SfDateTimePicker_1_Max) properties. The Min value must always be less than the Max value.
13
15
14
16
The `Value` property depends on the Min/Max with respect to [StrictMode](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Calendars.SfDateTimePicker-1.html#Syncfusion_Blazor_Calendars_SfDateTimePicker_1_StrictMode) property. For more information about StrictMode, refer to the [Strict Mode](./strict-mode) section from the documentation.
@@ -47,4 +49,42 @@ When the Min and Max properties are configured and the selected datetime value i
47
49
48
50

49
51
50
-
N> If the value of `Min` or `Max` properties changed through code behind, you have to update the `Value` property to set within the range.
52
+
N> If the value of `Min` or `Max` properties changed through code behind, you have to update the `Value` property to set within the range.
53
+
54
+
## Time Restriction
55
+
56
+
DateTimePicker provides an option to select a time value within a specified range by using the [MinTime](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Calendars.SfDateTimePicker-1.html#Syncfusion_Blazor_Calendars_SfDateTimePicker_1_MinTime) and [MaxTime](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Calendars.SfDateTimePicker-1.html#Syncfusion_Blazor_Calendars_SfDateTimePicker_1_MaxTime) properties. The MinTime value must always be less than the MaxTime value.
57
+
58
+
The `Value` property depends on the MinTime/MaxTime with respect to [StrictMode](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Calendars.SfDateTimePicker-1.html#Syncfusion_Blazor_Calendars_SfDateTimePicker_1_StrictMode) property. For more information about StrictMode, refer to the [Strict Mode](./strict-mode) section from the documentation.
59
+
60
+
The following code allows selecting a date within the range from 10:00 AM to 8:30 PM of each day.
public DateTime DateTimeValue { get; set; } = new DateTime(DateTime.Now.Year, DateTime.Now.Month, 9, 11, 0, 0);
69
+
public DateTime MinTime { get; set; } = new DateTime(DateTime.Now.Year, DateTime.Now.Month, 7, 10, 0, 0);
70
+
public DateTime MaxTime { get; set; } = new DateTime(DateTime.Now.Year, DateTime.Now.Month, 27, 20, 30, 0);
71
+
}
72
+
```
73
+
74
+

75
+
76
+
When the MinTime and MaxTime properties are configured and the selected time value is out-of-range or invalid, then the model value will be set to `out of range` time value or `null` respectively with highlighted `error` class to indicate the time is out of range or invalid.
0 commit comments