View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default 'If' with text values

Easier to create a table of numbers in the left column and results in the
right column, then use

=if(A1="","",vlookup(A1,Sheet2!A1:B1000,2,False))


Otherwise

Select Case Range("A1").Value
Case 1
res = "Hello"
Case 2
res = "Goodbye"
Case Else
res = "Not found"
End Select Case

msgbox Res



--
Regards,
Tom Ogilvy


"Liam" wrote in message
oups.com...
Thanks Tom, Sorry I wan't clear enough!

There are a whole bunch of possible values and outcomes, way too many
for a nested IF statement approach.

I was looking for a VB solution something along the lines of Case or If
?