Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
335
Validate and modify cell value while CellUpdating
posted

When a user is trying to modify a cell value in the grid, I want to validate the date that is being entered and display a modified value.

Like, if the user enters a name with leading and trailing space " abc ", I want to trim the string and display the modified value (just "abc").

I tried the following,

In CellUpdaing event

 e.cell.value = newValue //didn't work.

CellValuePresenter.FromCell(e.Cell).Editor.Value = newValue //also didn't work