2. The decision statement is a control
statement which is used to handle the
execution of the parts of a program.
The two basic types of decision
statements are IF statement and Select
Case statement.
3. If … ThenDecision Structures
The IF…Then decision structures
allow a condition in a program to
be evaluated or take course of
action based on the result .
The decision structure syntax is:
If total >=40 then label1.caption = Old
4. Use the multiple commands to execute
more
than one command in response to a
condition. This
bounds a range of statements between the If
statement and an End IF statement.
To handle a false conditions, the visual basic
uses the
else part of the If statement block.
6. Using Multiple IF statements
The else statement lets you
evaluate multiple
conditions. The ElseIf
statement allows you to
specify evaluated condition
when the first is false.
7. Syntax:
If condition 1 then
statements executed if conditional
is true
Else if condition 2 then
Statements executed if conditional is
true
Else
statements executed if none of the
conditions is true
End if