Create Round Form in C# Application

1) Create Simple Window Application (C#).

2) in the form set below property.

startposition : CenterScreen
MaximizeBox :False
MinimizeBox :False
Size :
Width :400
Height:400
FormBorderStyle :none

3)  in the form paint event put below code.

private void Form1_Paint(object sender, PaintEventArgs e)
{
System.Drawing.Drawing2D.GraphicsPath objGP = new System.Drawing.Drawing2D.GraphicsPath();
objGP.AddEllipse(new Rectangle(0, 0,this.Width, this.Height));
this.Region = new Region(objGP);
this.FormBorderStyle = FormBorderStyle.None;
}
Thnx.

4 responses to “Create Round Form in C# Application”

  1. Lili Avatar
    Lili

    Ehm….mau tanya….
    gimana kalau roundednya berbentuk persegi yang tiap sudutnya rounded???
    makasih ya….

    1. patriwala Avatar

      Hello Lili,
      I m not getting your language Please ask in English.

      thnx

  2. esteban Avatar
    esteban

    thanks patriwala

  3. Ajit Choudhary Avatar

    hi patriwal,
    tanx dude u r really genius…..i was try to find how to make a round form….and ur code is just awesome its sloved ma provlem .

Leave a Reply