using
System;
using
System.Collections.Generic;
using
System.ComponentModel;
using
System.Data;
using
System.Drawing;
using
System.Linq;
using
System.Text;
using
System.Threading.Tasks;
using
System.Windows.Forms;
namespace
WindowsFormsApp45 {
public
partial
class
Form1 : Form {
public
Form1()
{
InitializeComponent();
}
private
void
Form1_Load(
object
sender, EventArgs e)
{
GroupBox gbox =
new
GroupBox();
gbox.Location =
new
Point(179, 145);
gbox.Size =
new
Size(329, 94);
gbox.Text =
"Select Gender"
;
gbox.Name =
"Mybox"
;
gbox.BackColor = Color.LemonChiffon;
gbox.ForeColor = Color.Maroon;
this
.Controls.Add(gbox);
CheckBox c1 =
new
CheckBox();
c1.Location =
new
Point(40, 42);
c1.Size =
new
Size(49, 20);
c1.Text =
"Male"
;
gbox.Controls.Add(c1);
CheckBox c2 =
new
CheckBox();
c2.Location =
new
Point(183, 39);
c2.Size =
new
Size(69, 20);
c2.Text =
"Female"
;
gbox.Controls.Add(c2);
}
}
}