开发者

What is the equivalent of Form.IsValid() in WinForms?

开发者 https://www.devze.com 2023-02-03 22:09 出处:网络
I have a WinForm with an ErrorProvider which I set like this errorProvider1.SetError(textBox1, \"Error description\");

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

0

精彩评论

暂无评论...
验证码 换一张
取 消