Can I have a Case statement that can test for multiple values at one branch?
In the code below, I'd like the third Case statement to execute if MyString contains any of the characters "BFSTV".
Code:
Select Case UCase(MyString)
Case ""
MsgBox "Macro aborted", , MyName
Case "A"
Call SubA
Case "BFSTV" ??? 'What can go here???
Call SubMisc
Case "G"
Call SubG
Case Else
MsgBox "Invalid data:
End Select
That is, I'd like to run this test:
Code:
If instr(1,MyString,"BFSTV")>0