似是而非

导航

TextBox的判断

Dim id As String = Me.Label6.Text

Dim goods As String = Me.ComboBox1.SelectedValue

If id = "" Then

     MsgBox("入库编号不能为空!", MsgBoxStyle.Critical, Me.Text)

 Return

ElseIf goods = "" Then

     MsgBox("请选择易耗品!", MsgBoxStyle.Critical, Me.Text)

   Return

        ElseIf Not IsNumeric(Me.TextBox4.Text) Then

            MsgBox("数量必须是数字!", MsgBoxStyle.Critical, Me.Text)

            Return

        ElseIf CType(Me.TextBox4.Text, Integer) < 0 Then

            MsgBox("数量不能是负数!", MsgBoxStyle.Critical, Me.Text)

            Return

End If

posted on 2009-11-25 13:58  似是而非  阅读(247)  评论(0编辑  收藏  举报