RadzenDataGrid Inline Editing Using InputDate Control

I am using the data grid to edit datetime entries. I am using the InputDate control for editing because my client likes the control. When a row is in edit mode, the keyboard entry of dates and times is very erratic. For example, if I want to enter time in a 24 hour format and try to enter 15:25 using the keyboard, the hour value ends up being "5" and so does the minute value.

This is only a problem when a row is in edit mode. If I use the control as a Template instead of an EditTemplate, the control works properly. I think the grid is intercepting keyboard input somehow.

This does not work for keyboard input:

        <RadzenDataGridColumn TItem="VwDumpDelaysAndDumps" Property="StartTime" Title="Start Time" FormatString="@DateTimeFormat" Width="200px" OrderIndex="8">
            <EditTemplate Context="delay">
                <InputDate @bind-Value="@delay.StartTime" DisplayName="delayStart" Type="InputDateType.DateTimeLocal" bind-Value:format="@DateTimeStringFormat" class="bg-info-subtle rounded border border-primary" style="width:170px;height:30px" />
            </EditTemplate>
        </RadzenDataGridColumn>

But this works fine:

        <RadzenDataGridColumn TItem="VwDumpDelaysAndDumps" Property="StartTime" Title="Start Time" FormatString="@DateTimeFormat" Width="200px" OrderIndex="8">
            <Template Context="delay">
                <InputDate @bind-Value="@delay.StartTime" DisplayName="delayStart" Type="InputDateType.DateTimeLocal" bind-Value:format="@DateTimeStringFormat" class="bg-info-subtle rounded border border-primary" style="width:170px;height:30px" />
            </Template>
        </RadzenDataGridColumn>

Any ideas on how I can fix this?

No, the DataGrid will not intercept any keyboard input in this case. You can easily very this using our source code which is fully accessible for free and at your premises:


The breakpoint here will not be hit:

Thanks for the reply. However, the fact remains that my example code behaves exactly as explained. I can enter dates and times using the keyboard in the grid, or other forms, as long as I don't use the . I can use freely. The only difference here is the use of the EditTemplate.

Do you have any idea why this is behaving this way?

No, I don't know what might cause such issue.

Wow. I must be missing something. I can enter the following into any of your example code and the 24 hour format is NOT being honored.

<InputDate @bind-Value="myOrderDate" Type="InputDateType.DateTimeLocal" bind-Value:format="MM/dd/yyyy HH:mm" style="width:220px;height:30px" />


... code {
DateTime myOrderDate = DateTime.Now;
}

I was trying to reproduce your sample, but this is failing miserably.