Computer Science, asked by ayush655086, 11 months ago

what is select case statement in visual basic and what are its functions​

Answers

Answered by RishabhSemwal
0


If testexpression matches any Case expressionlist clause, the statements following that Case statement run up to the next Case, Case Else, or End Select statement. Control then passes to the statement following End Select. If testexpression matches an expressionlist clause in more than one Caseclause, only the statements following the first match run.

The Case Else statement is used to introduce the elsestatements to run if no match is found between the testexpression and an expressionlist clause in any of the other Casestatements. Although not required, it is a good idea to have a Case Else statement in your Select Case construction to handle unforeseen testexpression values. If no Case expressionlist clause matches testexpression and there is no Case Elsestatement, control passes to the statement following End Select.

Similar questions