Steps: Private Sub Data Grid View1_Cell Validating(By Val sender As System. Is In Edit Mode Then Dim c As Control = Data Grid View1. 2) Detach the event hander before the unwanted event triggers and re-attach after. so when i click the add button the cell validating event triggers i have posted the cell validating event do you know how to solve this thanxxx code!!!Something there is causing the cell validating event to fire. [Edit] The validating event is firing because focus is being moved from the DGV to the button.
Is there a way to change the dgv cell Style Format and cell Tag from within the Cell Validating event?I've tried a few things and have searched for answers without luck so far.In general, it is better to use the Cell Parsing event whenever you need to convert/change the value in a cell.event, value calculates when I leave the next cell.To make it more clear when I press Enter for the second time.