我正在尝试在我的咖啡店程序中添加长度检查……我已经整理了一些,但我看不出哪里出错了。
Dim Name As String
MsgBox("Welcome. You Are On The 'Hot Mornings' Self-Ordering Service", vbInformation, "Welcome To Hot Mornings!")
Name = InputBox("Please Enter Your Name", "Welcome To Hot Mornings!", , MsgBoxStyle.OkCancel)
If Len(Name <= 3) Then
Do Until Len(Name > 3)
MsgBox("Error!", vbExclamation, MsgBoxStyle.OkOnly)
MsgBox("An Error Occureed Earlier. We Are Currently Trying To fix This Issue.", vbInformation, "Error!")
Name = InputBox("Please Enter Your Name.", , "Must Contain More Than 3 Characters", MsgBoxStyle.OkCancel)
Loop
End If