Introduction: In this article, we will learn how to display a simple and conditional MessageBox in Windows Form in C#. It is very easy and simple. Description: Simple Message Box: Write MessageBox.Show("Text") in any control code (Button etc.) and write your message like: private void Simple_button_Click(object sender, EventArgs e)
{ MessageBox.Show("Hello MessageBox.....");
}
{ MessageBox.Show("Welcome to Simple MessageBox", "Simple",
MessageBoxButtons.OK, MessageBoxIcon.Information); }
if (DialogResult == DialogResult.Yes) { // any function } else { // any function }
You need to be a premium member to use this feature. To access it, you'll have to upgrade your membership.
Become a sharper developer and jumpstart your career.
$0
$
. 00
monthly
For Basic members:
$20
For Premium members:
$45
For Elite members: