View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default character limitations

myVal = 50
if lcase(Left(ActiveCell.Value,7)) = "example" then
ActiveCell.Offset(0,1).Value = myVal
End if

--
Regards,
Tom Ogilvy

"Chris" wrote in message
...
if the active cell has the first 7 characters = "example", I want it to

return a value in another cell. ie,

"example 7", "example fourty nine" and "example spiderman"

would all return a value, where as...

"7", "fourty nine" and "spiderman"

would not.

TIA
Chris