The handling of modal Dialogs can be completely implemented just by configuring them correctly in the Designer. There is no need to handle an OK_Click or a Cancel_Click event or even close the Dialog manually. (Although, the calling instance need to Dispose them manually!)
We should consider Analyzers for ensuring best practices here.
The handling of modal Dialogs can be completely implemented just by configuring them correctly in the Designer. There is no need to handle an
OK_Click
or aCancel_Click
event or even close the Dialog manually. (Although, the calling instance need toDispose
them manually!)We should consider Analyzers for ensuring best practices here.