vb TEXT1的内容跟TEXT2相同按Command2就弹出Form2不相同就MsgBox "错误"

来源:百度知道 编辑:UC知道 时间:2024/05/15 20:19:01
text1要文字不要数字
呵呵 还有多加个TEXT3
如果TEXT1等于TEXT3则弹出FORM3

if text1.text =text2.text then
form2.show
else
msgbox "错误"
end if

补充你的问题:

if text1.text =text2.text then
unload form1
form2.show
else
msgbox "错误"
end if

w问题补充:
哥们,你就不会变通吗,只要你明白了代码的意思 自己完全就可以写出来了。
If Text1.Text = Text2.Text Then
Unload Form1
form2.Show
ElseIf Text1.Text = Text3.Text Then
Unload Form1
form3.Show
Else
MsgBox "错误"
End If

If text1.text =text2.text then
unload me
form2.show
Else
MsgBox "错误", vbInformation + vbOKOnly
End if

if text1.text =text2.text then
unload form1
form2.show
else
msgbox "错误"
end if