Thread: case
View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
AlanW AlanW is offline
external usenet poster
 
Posts: 29
Default case

Is there any wild card such as * that can be used in Case statement.

I have a VBA statement like

For Each cell In Range("C1")
Select Case cell.Value
Case "ABoy"
cell.Offset(0, 1).Value = 10
Case "A*" <----------------------------i.e. A and all other thing except A
itself
cell.Offset(0, 1).Value = 20
Case Else
cell.Offset(0, 1).Value = 99
End Select
Next

Could someone please show me the right way to do it.

Many Thanks