How to use more than one condition in Select case statement
Posted on July 23, 2011
1 2 3 4 5 6 7 8 9 10 11 12 13 | 'Coding Basics - How to use more than one condition in Select case statement Sub Main() Select Case True Case Combo1.ListIndex = 0 And List1.ListIndex = 0 MsgBox "combo listindex = 0 and list.listindex=0" Case Combo1.ListIndex = 0 And List1.ListIndex = 1 MsgBox "combo listindex = 0 and list.listindex=1" Case Combo1.ListIndex = 0 And List1.ListIndex = 2 MsgBox "combo listindex = 0 and list.listindex=2" Case Else MsgBox "none of the previous" End Select End Sub |