|
Good day to everyone, I have a trouble from few days that I can't still solve so I hope someone can give me a suggestion on how to let it work properly. I have a datatable filled from a database and it's binded to a datagridview, now on this datatable I have a field where I never want to let a user let it NULL. So I try to catch the event inside the dataerror of my datagridview as saw on many post, and seems working, but if I do this chain of operation the control get crazy: 1: Select a cell not empty 2: enter in editmode inside it and erase all it's content 3: then dataerror pop and give me error and errorprovider set with error too 4: if I just press mouse button in another row of datagridview, or inside some textbox bounded inside my form then seems e.cancel stop working at all ...... What is the currect sequence for catch an error like this and never let the user do anything untill solve this problem ?? Thanks in advance to anyone will help me understand it. Good Day. |