This is a migrated thread and some comments may be shown as answers.

Radgridview winforms ActionOnLostFocus

1 Answer 139 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Fabrizio
Top achievements
Rank 1
Fabrizio asked on 27 May 2019, 06:20 AM
Hello everybody,

Can you tell me if exists the ActionOnLostFocus property in Winforms like Wpf ?

In fact, when I editing a cell I validating it in the CellValidating event or RowValidating.
But if during the editing I click on other control form's, the cell is not commited and the CellValidating event not fire.

How can I manage this situation appropriately?

Thank you
Best regards

1 Answer, 1 is accepted

Sort by
0
Dess | Tech Support Engineer, Principal
Telerik team
answered on 27 May 2019, 01:13 PM
Hello, Fabrizio,    

RadGridView provides a convenient way to perform validation before data is committed to the underlying data source. You can validate data by handling CellValidating event which is raised by RadGridView when the current cell changes or when the cell loses input focus (when pressing Enter key). Canceling this event prevents the user from exiting the cell until a valid editor value is entered or the edit process is canceled. The RowValidating event can be used the same way to prevent the user from exiting the current row. However, the editor will be closed in this case and the value will be committed to the underlying data source. If you are still experiencing any further difficulties, feel free to submit a support ticket from your account with additional information and a runnable sample project demonstrating the undesired behavior. Thus, out support staff will gladly assist you.

Note that most of the forum threads are reviewed by Telerik representatives and sometimes we address the questions asked by our customers in the forums as well. However, a post in the forum doesn't guarantee you a response from the Telerik support team. Moreover, threads are handled according to license and time of posting, so if it is an urgent problem, we suggest you use a support ticket, which would be handled before a forum thread. Thank you for your understanding.

Regards,
Dess | Tech Support Engineer, Sr.
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Tags
GridView
Asked by
Fabrizio
Top achievements
Rank 1
Answers by
Dess | Tech Support Engineer, Principal
Telerik team
Share this question
or