![]() |
Using the IF fuction for multiple cells
Can anyone help me correctly write an IF function for multiple cells? Here is
an example of what I am needing help with: A2, B2, C2, D2 are all yes or no responses. I need a formula that will tell me if anyone of these cells is "yes" then the outcome is yes. In an individual cell my formula is =IF(A2="Yes","Yes","")...this works fine but I need to expand to capture all cells. |
Using the IF fuction for multiple cells
Try this:
=IF(COUNTIF(A2:D2,"Yes"),"Yes","") -- Biff Microsoft Excel MVP "Mike" wrote in message ... Can anyone help me correctly write an IF function for multiple cells? Here is an example of what I am needing help with: A2, B2, C2, D2 are all yes or no responses. I need a formula that will tell me if anyone of these cells is "yes" then the outcome is yes. In an individual cell my formula is =IF(A2="Yes","Yes","")...this works fine but I need to expand to capture all cells. |
Using the IF fuction for multiple cells
Thanks works perfectly!!!!
Mike "T. Valko" wrote: Try this: =IF(COUNTIF(A2:D2,"Yes"),"Yes","") -- Biff Microsoft Excel MVP "Mike" wrote in message ... Can anyone help me correctly write an IF function for multiple cells? Here is an example of what I am needing help with: A2, B2, C2, D2 are all yes or no responses. I need a formula that will tell me if anyone of these cells is "yes" then the outcome is yes. In an individual cell my formula is =IF(A2="Yes","Yes","")...this works fine but I need to expand to capture all cells. |
Using the IF fuction for multiple cells
Hi Mike =IF(COUNTIF(A2:D2)0,"Yes","No") Strictly speaking the 0 isn't necessary, and it could be written as =IF(COUNTIF(A2:D2),"Yes","No") Make the final part "" if you want nothing to show in the cell instaed of "no" -- Roger Govier ------------------------------------------------------------------------ Roger Govier's Profile: http://www.thecodecage.com/forumz/member.php?userid=81 View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=82572 |
Using the IF fuction for multiple cells
You're welcome. Thanks for the feedback!
-- Biff Microsoft Excel MVP "Mike" wrote in message ... Thanks works perfectly!!!! Mike "T. Valko" wrote: Try this: =IF(COUNTIF(A2:D2,"Yes"),"Yes","") -- Biff Microsoft Excel MVP "Mike" wrote in message ... Can anyone help me correctly write an IF function for multiple cells? Here is an example of what I am needing help with: A2, B2, C2, D2 are all yes or no responses. I need a formula that will tell me if anyone of these cells is "yes" then the outcome is yes. In an individual cell my formula is =IF(A2="Yes","Yes","")...this works fine but I need to expand to capture all cells. |
All times are GMT +1. The time now is 11:18 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com