COUNTIF error when linking another workbook

cingraha

New Member
Joined
Jul 15, 2004
Messages
4
Hello, I have a question that hopefully has a simple answer. I am trying to do a countif in another workbook. I enter my formula:
=COUNTIF('path[filename]tab'!$AH$11:$AH$300,"yes")

So this formula works fine when I have the other workbook open, but the next day when I open up the file (with the formula in it) and I click "update" button on the "this workbook contains links to other data sources" popup I get a #VALUE! error in the cell. Does anyone know how to correct this?

As soon as I open up the linked workbook the error goes away, but I didn't think this is how its supposed to function. I thought you didn't have to open up any linked documents. All the documents are on my desktop, so its not a share drive issue.

To test it out, I tried doing just a simple link to cell A1 in the other workbook and that works fine, so I'm thinking its the COUNTIF function that causing the problem.

Thanks for any help!
 

Excel Facts

What do {} around a formula in the formula bar mean?
{Formula} means the formula was entered using Ctrl+Shift+Enter signifying an old-style array formula.
cingraha said:
...So this formula works fine when I have the other workbook open, but the next day when I open up the file (with the formula in it) and I click "update" button on the "this workbook contains links to other data sources" popup I get a #VALUE! error in the cell. Does anyone know how to correct this?

COUNTIF and SUMIF cannot reference a closed workbook (see http://support.microsoft.com/default.aspx?scid=kb;en-us;237188&Product=xlw97). If you need this functionality use...

{=COUNT(IF('path[filename]tab'!$AH$11:$AH$300="yes",1))}
 
Upvote 0
COUNTIF and SUMIF cannot reference a closed workbook (see http://support.microsoft.com/default.aspx?scid=kb;en-us;237188&Product=xlw97). If you need this functionality use...

{=COUNT(IF('path[filename]tab'!$AH$11:$AH$300="yes",1))}



Hello - I just tried this and was successful but i want to be able to use a "contains *" so instead of ...="yes" it would read ="8*" this works when taking from a sheet on the same workbook so i know it works, it must have to do with the linking... because if i use ...="8-1" instead it is perfect but i have many ranges and dont want to have type them all out. Any help would be appreciated.
 
Upvote 0
Hello - I just tried this and was successful but i want to be able to use a "contains *" so instead of ...="yes" it would read ="8*" this works when taking from a sheet on the same workbook so i know it works, it must have to do with the linking... because if i use ...="8-1" instead it is perfect but i have many ranges and dont want to have type them all out. Any help would be appreciated.

What did you exacly try?
 
Upvote 0
i tried:

{=COUNT(IF('path[filename]tab'!$F$6:$F$57="9*",1))}

{=COUNT(IF('path[filename]tab'!$F$6:$F$57="9-1",1))} is what works...
 
Upvote 0
i tried:

{=COUNT(IF('path[filename]tab'!$F$6:$F$57="9*",1))}

{=COUNT(IF('path[filename]tab'!$F$6:$F$57="9-1",1))} is what works...

One of:

Control+shift+enter, not just enter...

=COUNT(IF(LEFT($F$6:$F$57)="9",1))

=SUM(IF(LEFT($F$6:$F$57)="9",1))

Adjust to suit by adding the path bit.
 
Upvote 0
are you saying to type it as:

{=COUNT(IF(LEFT('path[filename]tab'!$F$6:$F$57="9",1)))}

It says the formula has an error when I do this (I am hitting CSE)
 
Upvote 0
right thats what i have (the {} just says that i'm hitting CSE)

then i get the "The formula you typed contans an error."
 
Upvote 0

Forum statistics

Threads
1,223,243
Messages
6,170,971
Members
452,371
Latest member
Frana

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