Howard Bash

asked on

# Excel 2007 In Cell Find function

I am using the find function to split cell strings into pieces. It works fine (mostly), unless the find fails in which case I get #NAME? for the value.

Really would I am trying to do is something like this:

=if(Find("x", G1, 1), "True Value", "False Value")

This sometimes gives the #NAME? value and so I refined the function to see where it is exploding and it is the FIND function, when it fails to find.

Any suggestions here would be greatly appreciated.

Thanks.

Really would I am trying to do is something like this:

=if(Find("x", G1, 1), "True Value", "False Value")

This sometimes gives the #NAME? value and so I refined the function to see where it is exploding and it is the FIND function, when it fails to find.

Any suggestions here would be greatly appreciated.

Thanks.

ASKER CERTIFIED SOLUTION

membership

This solution is only available to members.

To access this solution, you must be a member of Experts Exchange.

SOLUTION

membership

This solution is only available to members.

To access this solution, you must be a member of Experts Exchange.

Yes there are two same suggestions, I beat barry to it ;-)

I posted my suggestion before I saw that Saurabh had posted the same thing.....given that both are the same perhaps that's an indication that it's the best way to do it......if you want somrthing a little different try this

=IF(COUNT(Find("x",G1)),"True Value", "False Value")

No better, just different

regards, barry

=IF(COUNT(Find("x",G1)),"T

No better, just different

regards, barry

ASKER

=IF(COUNT(Find("x",G1)),"True Value", "False Value")

So, in this expression, Find("x", G1)) will not cause an error if no "x" found?

I will be at it in morning and post my finding.

Thanks.

So, in this expression, Find("x", G1)) will not cause an error if no "x" found?

I will be at it in morning and post my finding.

Thanks.

SOLUTION

membership

This solution is only available to members.

To access this solution, you must be a member of Experts Exchange.

ASKER

Thanks.