Wednesday, November 28, 2012

Adding Image Buttons to C# Windows Form

The C# Windows forms buttons are usually rectangular in shaper and take the default Grey color background, however there are instances where we need to make our forms more stylish, in this post we shall see on how to set Images to a Button in a C# Windows forms application.

1. Create a new / open an existing C# Windows application.
2. Create/Open the form which needs the Image Button.
3. Add a button to the Form
4. Set the following Properties to the Button (View -> Properties Window or Press F4 key)

          FlatAppearance -> BorderSize : 0
          FlatStyle : Flat
          Image: Browse and select the Required Image
          BackColor: Transparent
          ImageAlign: MiddleCenter


5. Save, Build and run the application.

6. The Button on the form should appear as follows.



Search Flipkart Products:
Flipkart.com

No comments: