【问题标题】:How to include checkbox validation on visual basic?如何在 Visual Basic 中包含复选框验证?
【发布时间】:2014-02-04 22:23:20
【问题描述】:

如果没有选中任何复选框,

然后 messagebox.show("请至少选择一个复选框")

如何在 vb 上做到这一点?

【问题讨论】:

    标签: validation checkbox


    【解决方案1】:

    考虑一下,如果您有两个复选框,则意味着验证必须是....

    if ((checkbox1.checked=false) and (checkbox2.checked=false) ) then
      msgbox "please select atleast one checkbox"
    else
      //the code you wanted to do
    end If
    

    这将按照您的要求进行!

    【讨论】:

      猜你喜欢
      • 2014-12-29
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2011-08-02
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多