If / Else Statements (VBScript)
If / else statements in VBScript are fairly standard as far as languages go. The syntax of an if statement is summarized by the folllowing snippet:
Dim Name
Name = InputBox("Please Enter Your Name")
If Name = "Stargazer" Then
MsgBox("Hello Stargazer!")
ElseIf Name = "Bob" Then
MsgBox("Hello Bob. You have a very Generic name.")
Else
MsgBox("Hello " & Name & ", how are you?")
End If
page revision: 0, last edited: 19 May 2008 00:00