c sharp buttons


Adding Button to C# windows Forms:

First off open your Project and then open  Your form in Design Tab . From tool box click on button ordrag your button to  Project form.Right Click on button to go to Button's Properties. Customize your Button.

Now Double Click on your button and to show a Message box do as follow :
 following is button Click Event . I.e what to do when the button is clicked .

 private void button1_Click(object sender, EventArgs e)
        {
            MessageBox.Show("Hello! CsharpTutorialsfree.blogspot.com");
}

when the above button is clicked tis will shows a message box  having a message passed in parameters.



No comments:

Post a Comment

Sending SMS Via Windows Form Application Using any Android Smart Phone  Source Code  using System ; using System . C...