Example:
' This rather tedious test shows nested select statements and if uncommented,
' the exit for statement
Sub Test ()
For x = 1 to 5
print x
Select Case x
Case 2
Print "Outer Case Two"
Case 3
Print "Outer Case Three"
'Exit For
Select Case x
Case 2
Print "Inner Case Two"
Case 3
Print "Inner Case Three"
'Exit For
Case Else' Must be something else.
Print "Inner Case Else:", x
End Select
Print "Done with Inner Select Case"
Case Else' Must be something else.
Print "Outer Case Else:",x
End Select
Next x
Print "Done with For Loop"
End Sub