GroupBox1









How do I use Group Box1
Below are practical examples compiled from projects for learning and reference purposes

Featured Snippets


File name: frmThi.cs Copy
184         private void btPre_Click(object sender, EventArgs e)
185         {
186             iRows -= sodonghienlen;
187             getData(iRows);
188             if (i < 100 && i > 1)
189             {
190                 i--;
191                 groupBox1.Text = " Nội dung câu hỏi " + i.ToString();
192             }
193             else
194                 return;
195         }
File name: frmThi.cs Copy
197         private void btNext_Click(object sender, EventArgs e)
198         {
199             test();
200             getdapan();
201             iRows += sodonghienlen;
202             getData(iRows);
203             if (i < 1)
204                 return;
205             else
206             {
207                 //strsoluongcauhoi1 = frmluachon.strsoluongcauhoi;
208                 i++;
209                 if (int.Parse(strsoluongcauhoi1)< i)
210                 {
211                     groupBox1.Text = " Nội dung câu hỏi " + i.ToString();
212                     if (MessageBox.Show("Bạn đã làm xong","Thông báo",MessageBoxButtons.OKCancel,MessageBoxIcon.Warning)== DialogResult.OK)
213                     {
214
215                     }
216                 }
217                 else
218                 {
219                     groupBox1.Text = " Nội dung câu hỏi " + i.ToString();
220                 }
221             }
222             j = j + 1;
223         }
File name: frmThiThat.cs Copy
135         void LoadCauHoiVaoControl()
136         {
137
138             try
139             {
140                 groupBox1.Text = "Câu: " + (CauHienTai + 1).ToString();
141                 lbCauHoi.Text = BangDeThi.Rows[CauHienTai][1].ToString();
142                 lbA.Text = BangDeThi.Rows[CauHienTai][2].ToString();
143                 lbB.Text = BangDeThi.Rows[CauHienTai][3].ToString();
144                 lbC.Text = BangDeThi.Rows[CauHienTai][4].ToString();
145                 lbD.Text = BangDeThi.Rows[CauHienTai][5].ToString();
146
147                 if (BangDeThi.Rows[CauHienTai][7].ToString().Contains("A"))
148                     checkBox1.Checked = true;
149                 if (BangDeThi.Rows[CauHienTai][7].ToString().Contains("B"))
150                     checkBox2.Checked = true;
151                 if (BangDeThi.Rows[CauHienTai][7].ToString().Contains("C"))
152                     checkBox3.Checked = true;
153                 if (BangDeThi.Rows[CauHienTai][7].ToString().Contains("D"))
154                     checkBox4.Checked = true;
155             }
156             catch (Exception ex)
157             { MessageBox.Show(ex.Message); }
158         }
File name: frmQlMuonSach.cs Copy
128         private void btnclear_Click(object sender, EventArgs e)
129         {
130             foreach (Control ctr in groupBox1.Controls)
131             {
132                 if (ctr is TextBox || ctr is ComboBox)
133                 {
134                     ctr.Text = "";
135                     cbxTenSach.Focus();
136                     txtMuon.Text = date.ToString("dd/MM/yyyy");
137                     txtTra.Text = date.AddDays(7).ToString("dd/MM/yyyy");
138                 }
139             }
140         }
File name: frmQLThe.cs Copy
72         private void btnclear_Click(object sender, EventArgs e)
73         {
74             foreach (Control ctr in groupBox1.Controls)
75             {
76                 if (ctr is TextBox || ctr is ComboBox || ctr is MaskedTextBox)
77                 {
78                     ctr.Text = "";
79                 }
80             }
81             cbxMaDG.Focus();
82             txtMaThe.ReadOnly = false;
83             mklNgayCap.Text = date.ToString("dd/MM/yyyy");
84             mktHan.Text = date.AddYears(1).ToString("dd/MM/yyyy");
85         }
File name: frmQLTraSach.cs Copy
56         private void btnclear_Click(object sender, EventArgs e)
57         {
58             foreach (Control ctr in groupBox1.Controls)
59             {
60                 if (ctr is TextBox || ctr is ComboBox || ctr is MaskedTextBox)
61                 {
62                     ctr.Text = "";
63                 }
64             }
65             cbxTenSach.Focus();
66         }
File name: frmQLUser.cs Copy
59         private void groupBox1_Enter(object sender, EventArgs e)
60         {
61
62         }
File name: frmQLUser.cs Copy
64         private void btnclear_Click(object sender, EventArgs e)
65         {
66             foreach (Control ctr in groupBox1.Controls)
67             {
68                 if (ctr is TextBox)
69                     ctr.Text = "";
70             }
71             TxTReadOnly(false);
72             txtusername.Focus();
73         }
File name: frmSach.cs Copy
145         private void btnclear_Click(object sender, EventArgs e)
146         {
147             foreach (Control ctr in groupBox1.Controls)
148             {
149                 if (ctr is TextBox && ctr is ComboBox)
150                 {
151                     ctr.Text = "";
152                 }
153             }
154             cbxtensach.Focus();
155         }
File name: frmSach.cs Copy
157         private void groupBox1_Enter(object sender, EventArgs e)
158         {
159
160         }

GroupBox1 125 lượt xem

Gõ tìm kiếm nhanh...