# IF Target Cell = Yes then 1, if No = 0 how do I set this up

1. ## IF Target Cell = Yes then 1, if No = 0 how do I set this up

I have a spreadsheet with YEs/No in Column A, and I need to output either a 1 or 0 in Column B. I know this is probably and easy solution but I just can't think of it for the life of my. I'm having a brainfart right now

2. ## Re: IF Target Cell = Yes then 1, if No = 0 how do I set this up

Put this in B1:

=--(A1="Yes")

then copy down.

Hope this helps.

Pete

3. ## Re: IF Target Cell = Yes then 1, if No = 0 how do I set this up

Currently trying to use a formula similar to =IF(D6=Yes,1,0) but its returning me a name error, Could it be because the cell I'm referencing Is getting it's data for a vlookup function or am I just messing something up?

4. ## Re: IF Target Cell = Yes then 1, if No = 0 how do I set this up

Nevermind that works perfectly! thanks I was missing the " around the Yes lol

5. ## Re: IF Target Cell = Yes then 1, if No = 0 how do I set this up

You would need to put quotes around the Yes in that formula:

=IF(D6="Yes",1,0)

That cell reference is a bit different to what you described in Post #1

Hope this helps.

Pete

There are currently 1 users browsing this thread. (0 members and 1 guests)

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1