|
|
Normally it is sufficient to use the conditional statement If....Then....Else for multiple options or selections programs. However, if there are too many different cases, the If...Then...Else structure could become too bulky and difficult to debug if problems arise. Fortunately, Visual Basic provides another way to handle complex multiple choice cases, that is, the Select Case.....End Case decision structure. The general format of a Select Case...End Case structure is as follow:
In the following example, I will show you how to process the grades of students according to the marks given.
|