We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

MinValue does not support DateTime.Now

Hello, there is a bug somewhere in the datetime/date picker compoments which causes UI to freeze after you select date. After digging around I found out that cause of this is setting Min="DateTime.Now" rather than assigning it to a variable and using it in the component. 

Not sure how far back it goes but version was working fine, as I noticed this only after upgrading from that version to latest 

Please fix this as I have few hundred components which needs updating because of this weird bug.

Working version:

<SfDatePicker @bind-Value="datepicker" Min="@MinDate" Placeholder="Select Date:" FloatLabelType="FloatLabelType.Always" />

@code {

    DateTime MinDate = DateTime.Now;


Not working version:

<SfDatePicker @bind-Value="datepicker" Min=DateTime.Now Placeholder="Select Date:" FloatLabelType="FloatLabelType.Always" />

3 Replies 1 reply marked as answer

EB Eimantas Baigys December 27, 2022 12:16 PM UTC

Also if Date picker component has ValueChanged property set for example I would like to validate selection and then depending on a result show a dialog - UI freeze for example (again this was working in

<SfDateTimePicker Value="Model.NewDueDate" Readonly="Model.AssignedToContractorUserId == null" ValueChanged="ValidateNewDueDate" TValue="DateTime?" Min="minNewAllocationDate" Step="15" AllowEdit=false Placeholder="Set new arrival time:" FloatLabelType="FloatLabelType.Always" />

async Task ValidateNewDueDate(DateTime? newDueDate)


        if (Some conditions are true)


            //This is a prerendered SfDialog Compoment and a model simply represends data it should render on open. It also has a callbacks on button clicks

            await ShowConfirmationDialog(new ConfirmationDialogModel()







            Model.NewDueDate = newDueDate;




SP Sureshkumar P Syncfusion Team January 3, 2023 11:32 AM UTC

Hi Eimantas,

Thanks for your shared information. We have confirmed the reported issue is an issue at our end and this fix will be included in our any one of upcoming patch release,

You can track the status of this issue from the below feedback.

Feedback: https://www.syncfusion.com/feedback/40172

Disclaimer: Inclusion of this solution in the weekly release may change due to other factors including but not limited to QA checks and works reprioritization


Sureshkumar P

SP Sureshkumar P Syncfusion Team February 7, 2023 04:46 AM UTC

Hi All,    

We have fixed your reported issue from our end in the latest 20.4.43 version. So, we suggest you upgrade to our latest version to resolve the current issue.

Find the release notes here: https://blazor.syncfusion.com/documentation/release-notes/20.4.43?type=all#datepicker


Sureshkumar P

Marked as answer
Live Chat Icon For mobile
Up arrow icon