Control and Loop Structures in VB 6.0
CONTROL STRUCTURES IN VB 6.0 Control Statements are used to control the flow of program's execution. Visual Basic supports control structures such as If... Then, If...Then ...Else, NestedIf...Then...Else and Select...Case i. If...Then selection structure The If...Then selection structure performs an indicated action only when the condition is True; otherwise the action is skipped. Syntax of the If...Then selection If <condition> Then statement End If Example If average>75 Then txtGrade.Text = "A" End If ii. If...Then...Else selection structure The If...Then...Else selection structure allows the programmer to specify that a different action is to be performed when the condition is True than when the condition is False. Syntax of the If...Then...Else selection If <condition > Then statements Else statements End If Example If average>50 Then txtGrade.Text = "Pass" Else txtGrade....