Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 12
Default Countif failing when referencing an external file

Hi

Something wierd is happening with a COUNTIF formula I have set up...

I have two spreadsheets (let's call them "Summary" and "Detail")

Column A on the Detail spreadsheet contains a variable amount of numbers

The Summary spreadsheet has two formulas, both of which reference the Detail
spreadsheet. The first formula counts the amount of numbers in column A
with the formula:

=COUNT('[Detail.xls]Sheet 1'!$A$1:$A$100)

The second formula interegates the same range on the Detail spreadsheet, but
counts the number of times the number in the range is less than 10, with the
formula:

=COUNTIF('[Detail.xls]Sheet 1'!$A$1:$A$100,"<10")

When the Detail spreadsheet is open, both formulas work fine. However, when
I close the Detail spreadsheet, the COUNTIF formula returns #VALUE!. The
COUNT formula continues to work OK.

Any ideas why the COUNTIF formula is failing?

Thanks in advance
Alex


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,337
Default Countif failing when referencing an external file

Some functions, such as indirect, do not work with closed wbs. try

=SUMPRODUCT(([filename]Sheet1!$A$1:$A$15=1)*([filename]Sheet1!$A$1:$A$15))
=sumproduct('[Detail.xls]Sheet 1'!$A$1:$A$100<10)*1)
or
sumproduct('[Detail.xls]Sheet 1'!$A$1:$A$100<10)*([Detail.xls]Sheet
1'!$A$1:$A$100))


"Alex" <@ wrote in message ...
Hi

Something wierd is happening with a COUNTIF formula I have set up...

I have two spreadsheets (let's call them "Summary" and "Detail")

Column A on the Detail spreadsheet contains a variable amount of numbers

The Summary spreadsheet has two formulas, both of which reference the

Detail
spreadsheet. The first formula counts the amount of numbers in column A
with the formula:

=COUNT('[Detail.xls]Sheet 1'!$A$1:$A$100)

The second formula interegates the same range on the Detail spreadsheet,

but
counts the number of times the number in the range is less than 10, with

the
formula:

=COUNTIF('[Detail.xls]Sheet 1'!$A$1:$A$100,"<10")

When the Detail spreadsheet is open, both formulas work fine. However,

when
I close the Detail spreadsheet, the COUNTIF formula returns #VALUE!. The
COUNT formula continues to work OK.

Any ideas why the COUNTIF formula is failing?

Thanks in advance
Alex




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Referencing External files with slightly different names PeteJ Excel Worksheet Functions 4 November 13th 09 02:04 AM
Referencing External Data Smiley[_2_] Excel Discussion (Misc queries) 1 August 18th 08 07:21 PM
Indirect referencing of external spreadsheets GSM Excel Discussion (Misc queries) 4 February 16th 08 01:59 PM
External References - Forcing Relative File Referencing Brad Abbott Excel Worksheet Functions 0 March 21st 07 04:57 AM
External links referencing URL with parameter Dmitry Bogdanov Excel Discussion (Misc queries) 0 April 5th 06 01:40 PM


All times are GMT +1. The time now is 08:36 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"