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
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Cell Validation

Thread ID:





22871 Dec 28,2004 03:53 AM UTC Dec 28,2004 11:35 PM UTC WinForms 1
Tags: GridControl
Administrator [Syncfusion]
Asked On December 28, 2004 03:53 AM UTC

Hi, I need to validate the values entered in the cells of the gridcontrol. I am handling currentcellvalidating event for the same. My requirement is suppose the validation fails then the cell should contain the last valid value entered in it. e.g. Suppose for my cell only numeric values can be entered. Initially it has value 1. Then the user enters "abc" so this being invalid the cell should retain 1 as the cellvalue.

Administrator [Syncfusion]
Replied On December 28, 2004 11:35 PM UTC

In CurrentCellValidating, you can get the original value using string s = this.grid[grid.CurrentCell.RowIndex, grid.CurrentCell.Colindex].Text; Then set this text into the renderer: grid.CurrentCell.Renderer.Control.Text = s;


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon