这句话你应经判断了7个了,For i = 0 To 6 Step 1
    是不是这个问题呢?

解决方案 »

  1.   

    Public Function Emptystring(ByVal con As TextBox) As Boolean
              If Trim(con.Text) = "" Then
              Emptystring = True
          End If
      End Function
    我在含有12个textbox控件,是textbox数组控件.
    我想在前6个控件判断它的text是否为空.
    For i = 0 To 6 Step 1
        If len(trim(a2_txtcom(i))) <0  Then
            MsgBox "带有*号的填写项不能为空!", vbOKOnly, "出错提示"
        
        Exit Sub
        End If
    Next
    同时你在看看你的引用此函数的事件,是否有连锁反映
      

  2.   

    Public Function Emptystring(ByVal con As TextBox) As Boolean
              If Trim(con.Text) = "" Then
              Emptystring = True
          End If
      End Function
    我在含有12个textbox控件,是textbox数组控件.
    我想在前6个控件判断它的text是否为空.
    For i = 0 To 6 Step 1
        If len(trim(a2_txtcom(i))) <0  Then
            MsgBox "带有*号的填写项不能为空!", vbOKOnly, "出错提示"
        
        Exit Sub
        End If
    Next
    同时你在看看你的引用此函数的事件,是否有连锁反映