Here's an extract from MSDN on the topic. This will give the exact syntax and usage. Hope it helps. What MustBNuts has given is the perfect solution. :up:
If varBusName = "Citi" Then
Select Case varYrA
Case "2002"
varDB = "Training_Delivery_Data.mdb"
'more Cases for each year
End Select
Else
Select Case varYrA
Case "2002"
varDB = "Training_Delivery_DataSears.mdb"
'more Cases for each year
End Select
End If
If varBusName = "Citi" Then
Select Case varYrA
Case "2002"
varDB = "Training_Delivery_Data.mdb"
'more Cases for each year
End Select
ElseIF varBusName = "Sears" Then
Select Case varYrA
Case "2002"
varDB = "Training_Delivery_DataSears.mdb"
'more Cases for each year
End Select
Else
'Redirect to an Error Page instructing them to make a choice in the dropdowns
[I][B]How do I get it to check for both values before posting?[/B][/I]
End If
Select Case testexpression
[Case expressionlist-n
[statements-n]] ...
[Case Else
[elsestatements]]
End Select
If condition Then
[statements]
[ElseIf condition-n Then
[elseifstatements] ...
[Else
[elsestatements]]
End If