//循环整个form上的控件
 foreach (Control c in this.Controls)
            {
                //看看是不是checkbox
                if (c is CheckBox)
                {
                    //将找到的control转化成checkbox
                    CheckBox ck = c as CheckBox;
                    //判断是否选中
                    if (ck.Checked)
                    {
                       //该复选框被选择


                    }
                }else if ...
    

            }                            

 

相关文章:

  • 2022-12-23
  • 2021-09-02
  • 2021-10-19
  • 2021-12-08
  • 2022-01-09
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-12-02
  • 2022-12-23
  • 2021-11-21
  • 2021-07-03
  • 2021-12-01
相关资源
相似解决方案