.net - How to return the result of dialog window work in the moment of its closing? -


everyone knows messagebox.show() method, returns dialogresult value after dialog closed. how can implement such method in dialog class?

class mydialog : form {

public static mydialogresult show() {}; 

}

the problem, can guess, method returns value after user clicks button in dialog.

you can set dialogresult property on button. if button clicked specified value returned showdialog() method.


Comments

Popular posts from this blog

c++ - How do I get a multi line tooltip in MFC -

asp.net - In javascript how to find the height and width -

c# - DataTable to EnumerableRowCollection -