COUNTIF against closed workbooks - #VALUE!

SimonGeoghegan

Board Regular
Joined
Nov 5, 2013
Messages
68
Hi All,

I currently have the below formula looking to calculate the percentage of actions that have been completed on an action plan. Column C counts how many actions there are, and Column N counts how many been completed. There are a number of action plans, so I have this formula multiple times referencing different workbooks.

Excel Formula:
=COUNTIF('C:\Users\sgeoghegan\Desktop\Clinical Audits\[Book2.xlsm]Clinical Action Plan'!$N:$N,"NOT OK")/COUNTA('C:\Users\sgeoghegan\Desktop\Clinical Audits\[Book2.xlsm]Clinical Action Plan'!$C:$C)

All these workbooks are closed and there #VALUE! is displayed. I have seen threads relating to using array based formulas but I could only find alternatives using SUMPRODUCT instead of a SUMIF. In my case, i'm using COUNTIF and wondered if there was an alternative approach?

Thanks in advance.

Regards,
Simon
 

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
For your reference:
Book1
ABCDE
1FruitPriceSUMPRODUCTCOUNTIF
2Apple1022
3Orange20
4Pear3011
5Peach40
Sheet1
Cell Formulas
RangeFormula
D2D2=SUMPRODUCT(N(B2:B5>20))
E2E2=COUNTIF(B2:B5,">20")
D4D4=SUMPRODUCT((LEFT(A2:A5)="P")*(B2:B5>35))
E4E4=COUNTIFS(A2:A5,"P*",B2:B5,">35")
 
Upvote 0
SUMPRODUCT works for a count too, but you really don't want to use entire columns with it. You'd use something like:

Excel Formula:
=SUMPRODUCT(--('C:\Users\sgeoghegan\Desktop\Clinical Audits\[Book2.xlsm]Clinical Action Plan'!$N$1:$N$1000="NOT OK"))/COUNTA('C:\Users\sgeoghegan\Desktop\Clinical Audits\[Book2.xlsm]Clinical Action Plan'!$C$1:$C$1000)
 
Upvote 0
Solution

Forum statistics

Threads
1,214,954
Messages
6,122,462
Members
449,085
Latest member
ExcelError

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