Answers for "button to show alert in web html c#"

C#
2

alert message in c# windows application

string message = "Simple MessageBox";  
MessageBox.Show(message);
Posted by: Guest on September-20-2021
1

alert message in c# windows application

string message = "Do you want to close this window?";  
string title = "Close Window";  
MessageBoxButtons buttons = MessageBoxButtons.YesNo;  
DialogResult result = MessageBox.Show(message, title, buttons);  
if (result == DialogResult.Yes) {  
    this.Close();  
} else {  
    // Do something  
}
Posted by: Guest on September-20-2021

C# Answers by Framework

Browse Popular Code Answers by Language