I would like to use the following function,

=IF(SEARCH(" ",B2,1)>0, do something, else do something)

This works fine unless B2 does not contain a space. If this occurs I get error #VALID!. I only want to perform the operation if B2 has content that is separated by a space.

Seems simple. Anyone have a solution for me?

Thank you in advance.

Phil.