What is the equivalent of Form.IsValid() in WinForms?
I have a WinForm with an ErrorProvider which I set like this
errorProvider1.SetError(textBox1, "Error description");
How can I check if all the data is valid like you do开发者_运维知识库 in ASP.NET as Form.IsValid()?
Do I have to use errorProvider1.GetError() for every control that I validate? Is there a better way?
There is no such thing you will have to create yourself. See this question WinForm UI Validation
精彩评论