繁体   English   中英

Textbox.text = "" 的反义词是什么

[英]What is the opposite of Textbox.text = ""

你知道 Textbox1.text = "" 的反义词吗? 或者这个Textbox1.text = not empty怎么办? 因为我希望用户在文本框上输入字符。

示例:如果用户选中此单选按钮(是/否),则必须填写它旁边的文本框。 就像这个问题:你有信心吗? 如果是,为什么?

从 Jimi 和 Emond 那里得到了一些答案。 他们用这些代码帮助我。

Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click
    If RadioButton1.Checked = True Then
        MsgBox("Complete")
    ElseIf RadioButton2.Checked = True Then
        If Not String.IsNullOrEmpty(TextBox10.Text.Trim()) Then
            MsgBox("Complete")
        Else
            MsgBox("Empty textbox")

        End If
    End If
End Sub

Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click
    If RadioButton3.Checked = True Then
        MsgBox("Complete")
    ElseIf RadioButton4.Checked = True Then
        If String.IsNullOrEmpty(TextBox11.Text) Then
            MsgBox("Empty textbox")
        Else
            MsgBox("Complete")
        End If
    End If

End Sub

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM