RazenGrid in-line edit drops edit mode when checkbox changed #50

Closed
opened 2026-01-29 17:30:45 +00:00 by claunia · 2 comments
Owner

Originally created by @vouksh on GitHub (Feb 25, 2021).

Describe the bug
When using the RadzenGrid in-line edit functionality, if you use any sort of Checkbox control, the edit mode gets switched off as soon as the value is changed, but the changes don't save. In order to save it, you have to re-enable edit mode for the row, then save changes to push them up to the server.
This only happens the first time edit mode is triggered on the page. After the first time it ends edit mode, it will function normally.

To Reproduce
Steps to reproduce the behavior:

  1. Create a component using RadzenGrid
  2. Use in-line editing, create an EditTemplate for a column that is a boolean property, use either InputCheckbox or RadzenCheckbox
  3. Enable edit mode in browser and change the state of the property. Edit mode will stop and server never receives new info.

Alternatively link your repo with a sample project that can be run.

Expected behavior
Allow boolean checkboxes in inline editing.

Screenshots
image
image

Desktop (please complete the following information):

  • OS: Windows 10 20H2
  • Browser: Edge
  • Version 88.0.705.74 (Official build) (64-bit)

Additional context
Working around this using a dropdown, but would prefer to use a checkbox.

Originally created by @vouksh on GitHub (Feb 25, 2021). **Describe the bug** When using the RadzenGrid in-line edit functionality, if you use any sort of Checkbox control, the edit mode gets switched off as soon as the value is changed, but the changes don't save. In order to save it, you have to re-enable edit mode for the row, then save changes to push them up to the server. This only happens the first time edit mode is triggered on the page. After the first time it ends edit mode, it will function normally. **To Reproduce** Steps to reproduce the behavior: 1. Create a component using RadzenGrid 2. Use in-line editing, create an EditTemplate for a column that is a boolean property, use either InputCheckbox or RadzenCheckbox 3. Enable edit mode in browser and change the state of the property. Edit mode will stop and server never receives new info. 4. Alternatively link your repo with a sample project that can be run. **Expected behavior** Allow boolean checkboxes in inline editing. **Screenshots** ![image](https://user-images.githubusercontent.com/3097831/109192799-b068ea00-7765-11eb-8df0-eac72434a4df.png) ![image](https://user-images.githubusercontent.com/3097831/109192923-d2626c80-7765-11eb-9011-8c4d1b1336b6.png) **Desktop (please complete the following information):** - OS: Windows 10 20H2 - Browser: Edge - Version 88.0.705.74 (Official build) (64-bit) **Additional context** Working around this using a dropdown, but would prefer to use a checkbox.
Author
Owner

@enchev commented on GitHub (Feb 27, 2021):

I'm unable to reproduce this on our demo:
image
image

@enchev commented on GitHub (Feb 27, 2021): I'm unable to reproduce this on our demo: ![image](https://user-images.githubusercontent.com/5804953/109378260-d7e0c380-78d9-11eb-8664-0d35bf2bb6c4.png) ![image](https://user-images.githubusercontent.com/5804953/109378266-e0d19500-78d9-11eb-9128-e5819ee9a231.png)
Author
Owner

@MonoRojo99 commented on GitHub (Aug 22, 2022):

I have had this same issue, and couldn't decipher what the problem was until I realized the textboxes that were causing the same edit mode exit, were also the ones in the GetHashCode method override for the object in the table. Once the override is removed from the object, the grid works fine during editing. There must be a background hashing setup that is triggering a change in state when it doesn't match an internal hash compared to the custom GetHashCode output is my guess.

@MonoRojo99 commented on GitHub (Aug 22, 2022): I have had this same issue, and couldn't decipher what the problem was until I realized the textboxes that were causing the same edit mode exit, were also the ones in the GetHashCode method override for the object in the table. Once the override is removed from the object, the grid works fine during editing. There must be a background hashing setup that is triggering a change in state when it doesn't match an internal hash compared to the custom GetHashCode output is my guess.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/radzen-blazor#50