ElseIf Structure


Sub ElseIf_Structure()
Dim marks As Integer
marks = Application.InputBox("Give Marks")
If marks >= 33 And marks <= 50 Then
MsgBox "Third"
ElseIf marks > 50 And marks < 60 Then
MsgBox "Secend"
ElseIf marks >= 60 Then
MsgBox "First"
Else
MsgBox "Fail"
End If
End Sub

Comments

Popular posts from this blog

50 Excel VBA Oral Interview Questions