Windows Develop Bookmark and Share   
 index > Windows Forms Designer > How to make the buttons round in the VS 2008
 

How to make the buttons round in the VS 2008

Hi I am working on a couple of projects and I would like to ask you if there is a possibility to make the buttons round instead of the usual rectangle?
MMOHM  Monday, June 08, 2009 8:39 PM

Hi MMOHM,

The shape of Winform button control is not easy to change. That's an easy job for WPF project. But if you still need to use Winform for your project, you can host WPF control into it.

Please read the following sample.
http://msdn.microsoft.com/en-us/library/ms742215.aspx

You should first made your custom button(round corner) control in WPF(with XAML will be ok), then add that button into Winform. ElementHost is the class that can host WPF control.

For the information of making a round corner button in WPF, you can post on WPF forum.

Sincerely,
Kira Qian


Please mark the replies as answers if they help and unmark if they don't.
Kira Qian  Wednesday, June 10, 2009 8:05 AM

Hi MMOHM,

The shape of Winform button control is not easy to change. That's an easy job for WPF project. But if you still need to use Winform for your project, you can host WPF control into it.

Please read the following sample.
http://msdn.microsoft.com/en-us/library/ms742215.aspx

You should first made your custom button(round corner) control in WPF(with XAML will be ok), then add that button into Winform. ElementHost is the class that can host WPF control.

For the information of making a round corner button in WPF, you can post on WPF forum.

Sincerely,
Kira Qian


Please mark the replies as answers if they help and unmark if they don't.
Kira Qian  Wednesday, June 10, 2009 8:05 AM

You can use google to search for other answers

Custom Search

More Threads

• How to implement a design-time complex property custom editor
• Argh: Label.Padding.All
• Toolbox error when using System.Drawing.Design.ToolboxItem
• Why are SnapLines and SnapToGrid Mutually Exclusive?
• Bug? Accept/CancelButton properties reset with inherited textbox control on form
• Right way to do a custom control?
• CSS
• Error after adding new form
• Design time support for protected property
• _MYFORMS=True What is this constant and why designer gets lost when not having it?