Formula Help --- IF statement

Joneye

Well-known Member
Joined
May 28, 2010
Messages
785
Office Version
  1. 365
  2. 2019
Platform
  1. Windows
  2. MacOS
My formula reads from another table, it counts how many dates are the same as the date in cell A2, instead of having 1 how would I report words here as my formula has a counting aspect to it.


<b>Excel 2003</b><table cellpadding="2.5px" rules="all" style=";background-color: #FFFFFF;border: 1px solid;border-collapse: collapse; border-color: #A6AAB6"><colgroup><col width="25px" style="background-color: #E0E0F0" /><col /><col /></colgroup><thead><tr style=" background-color: #E0E0F0;text-align: center;color: #161120"><th></th><th>A</th><th>B</th></tr></thead><tbody><tr ><td style="color: #161120;text-align: center;">2</td><td style="text-align: right;;">14/03/2011</td><td style="text-align: center;;">1</td></tr></tbody></table><p style="width:3.6em;font-weight:bold;margin:0;padding:0.2em 0.6em 0.2em 0.5em;border: 1px solid #A6AAB6;border-top:none;text-align: center;background-color: #E0E0F0;color: #161120">Sheet2</p><br /><br /><table width="85%" cellpadding="2.5px" rules="all" style=";border: 2px solid black;border-collapse:collapse;padding: 0.4em;background-color: #FFFFFF" ><tr><td style="padding:6px" ><b>Worksheet Formulas</b><table cellpadding="2.5px" width="100%" rules="all" style="border: 1px solid;text-align:center;background-color: #FFFFFF;border-collapse: collapse; border-color: #A6AAB6"><thead><tr style=" background-color: #E0E0F0;color: #161120"><th width="10px">Cell</th><th style="text-align:left;padding-left:5px;">Formula</th></tr></thead><tbody><tr><th width="10px" style=" background-color: #E0E0F0;color: #161120">B2</th><td style="text-align:left">=IF(<font color="Blue">A2='Method 1'!E12,COUNTIF(<font color="Red">'Method 1'!E12:E15,Sheet2!A2</font>),"none"</font>)</td></tr><tr><th width="10px" style=" background-color: #E0E0F0;color: #161120">B3</th><td style="text-align:left">=IF(<font color="Blue">A3='Method 1'!E13,COUNTIF(<font color="Red">'Method 1'!E13:E16,Sheet2!A3</font>),"none"</font>)</td></tr></tbody></table></td></tr></table><br />
 

Excel Facts

Square and cube roots
The =SQRT(25) is a square root. For a cube root, use =125^(1/3). For a fourth root, use =625^(1/4).
As requested,

<b>Excel 2003</b><table cellpadding="2.5px" rules="all" style=";background-color: #FFFFFF;border: 1px solid;border-collapse: collapse; border-color: #A6AAB6"><colgroup><col width="25px" style="background-color: #E0E0F0" /><col /><col /><col /><col /></colgroup><thead><tr style=" background-color: #E0E0F0;text-align: center;color: #161120"><th></th><th>B</th><th>C</th><th>D</th><th>E</th></tr></thead><tbody><tr ><td style="color: #161120;text-align: center;">11</td><td style="font-weight: bold;;">Date</td><td style="font-weight: bold;;">Test</td><td style="font-weight: bold;text-align: center;;"></td><td style="font-weight: bold;;">Re Test Date</td></tr><tr ><td style="color: #161120;text-align: center;">12</td><td style="text-align: right;;">14/03/2010</td><td style=";">Annual</td><td style="text-align: center;;">12</td><td style="text-align: right;;">14/03/2011</td></tr><tr ><td style="color: #161120;text-align: center;">13</td><td style="text-align: right;;">13/02/2010</td><td style=";">Quarterly</td><td style="text-align: center;;">3</td><td style="text-align: right;;">13/05/2010</td></tr><tr ><td style="color: #161120;text-align: center;">14</td><td style="text-align: right;;">01/01/2011</td><td style=";">Monthly</td><td style="text-align: center;;">1</td><td style="text-align: right;;">01/02/2011</td></tr><tr ><td style="color: #161120;text-align: center;">15</td><td style="text-align: right;;">25/07/2011</td><td style=";">Monthly</td><td style="text-align: center;;">1</td><td style="text-align: right;;">25/08/2011</td></tr></tbody></table><p style="width:4.8em;font-weight:bold;margin:0;padding:0.2em 0.6em 0.2em 0.5em;border: 1px solid #A6AAB6;border-top:none;text-align: center;background-color: #E0E0F0;color: #161120">Method 1</p><br /><br />
 
Upvote 0
May Be:
Array Formula

{=COUNT(IF(Sheet2!A2=Method1!E12,IF(Method1!E12:E15=Sheet2!A2,Method1!E2:E5)))}


Enter by Ctrl+Shift+Enter
 
Upvote 0
I think you mean you want the word "one" instead of the figure 1. If so, wrap a CHOOSE function round the COUNTIF function thus:

=IF(A2='Method 1'!E12,CHOOSE(COUNTIF('Method 1'!E12:E15,Sheet2!A2),"one","two","three","four"),"none")

You're limited to 29 arguments not just four. Hope thats enough.
 
Upvote 0
Grizlie,

Many thanks great help - perfect.
 
Upvote 0

Forum statistics

Threads
1,224,585
Messages
6,179,696
Members
452,938
Latest member
babeneker

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top