While...Wend statement executes a series of statements as long as a given condition is True.
condition: Numeric or string expression that evaluates to True or False. If condition is Null, condition is treated as False.
statements: One or more statements executed while condition is True.
'While...Wend Counter =1 While Counter < 4 Total =Inputbox("Please enter the total marks in numbers") If Total < 50 Then MsgBox "Fail" ElseIf Total >=50 and Total <=60 then Msgbox "Second Class" ElseIf Total >60 and Total <80 then Msgbox "First Class" ElseIf Total >=80 then Msgbox "Distinction" Else Msgbox "Invalid Marks" End If Counter=counter + 1 Wend