Just now I noticed that Visual Studio shows a message box with details when a property is set to an invalid value. For example:
Is it possible to make this type of message box in WinForms?
I have tried the following code:
MessageBox.Show("Error in Division Fill.
" + ex.Message,
"Information",
MessageBoxButtons.OK,
MessageBoxIcon.Information,
MessageBoxOptions.RightAlign);
But this produced the following error:
Error 24 The best overloaded method match for 'System.Windows.Forms.MessageBox.Show(string, string, System.Windows.Forms.MessageBoxButtons, System.Windows.Forms.MessageBoxIcon, System.Windows.Forms.MessageBoxDefaultButton)' has some invalid arguments
G:JagadeeswaranNov 17MCS-SPS SchoolMCS-SPS SchoolCertificateTransfer.cs 164 21 MCS-SPS School
How can I fix this error and get a message box that shows additional details?
See Question&Answers more detail:os