#1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3
Default Countif

Greetings,
I'm having a problem using countif function. I'm trying count values from
two separate spreadsheet. I'm not getting any result, it returns the formula
in the cell.

here is the formula i'm using below
=countif('[Primecure_Providers.xls]Network GP & PC Medicentre'!$A:$A,A2)
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 896
Default Countif

possible reasons:
1. as far as I know COUNTIF works with open workbooks only
2. replace Network GP & PC Medicentre with Network_GP_&_PC_Medicentre
3. CTRL+` (or Tools-Options-View tab-Window options, uncheck
Formulas) to switch


On 29 Kwi, 09:35, Master T wrote:
Greetings,
I'm having a problem using countif function. I'm trying count values from
two separate spreadsheet. I'm not getting any result, it returns the formula
in the cell.

here is the formula i'm using below
=countif('[Primecure_Providers.xls]Network GP & PC Medicentre'!$A:$A,A2)


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,520
Default Countif

Replace Book1, Sheet1 and Sheet2 to suit your requirement

=COUNTIF([Book1]Sheet1!$A:$A,A2)+COUNTIF([Book1]Sheet2!$A:$A,A2)

If this post helps click Yes
---------------
Jacob Skaria


"Master T" wrote:

Greetings,
I'm having a problem using countif function. I'm trying count values from
two separate spreadsheet. I'm not getting any result, it returns the formula
in the cell.

here is the formula i'm using below
=countif('[Primecure_Providers.xls]Network GP & PC Medicentre'!$A:$A,A2)

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default Countif

If the cell displays the formula then the cell is probably formatted as
text.

Select the cell
Goto the menu FormatCellsNumber tabGeneralOK
With the cell still selected hit function key F2 then hit enter

The formula should now work if the source file is open, however, COUNTIF
doesn't work on closed files. Use SUMPRODUCT instead.

=SUMPRODUCT(--('[Primecure_Providers.xls]Network GP & PC
Medicentre'!$A$1:$A$100=A2))

However (!!!!!), SUMPRODUCT *can't* use entire columns as range references
unless you're using Excel 2007.

--
Biff
Microsoft Excel MVP


"Master T" wrote in message
...
Greetings,
I'm having a problem using countif function. I'm trying count values from
two separate spreadsheet. I'm not getting any result, it returns the
formula
in the cell.

here is the formula i'm using below
=countif('[Primecure_Providers.xls]Network GP & PC Medicentre'!$A:$A,A2)



  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,231
Default Countif

Jacob Skaria wrote...
Replace Book1, Sheet1 and Sheet2 to suit your requirement

=COUNTIF([Book1]Sheet1!$A:$A,A2)+COUNTIF([Book1]Sheet2!$A:$A,A2)

....

Problem is that COUNTIF would return #REF! if the referenced workbook
(s) is(are) closed. When working with external references, best to use
SUMPRODUCT rather than either COUNTIF or SUMIF.

That said, if all one wants to do is count, and if the range(s) to be
counted is(are) all numbers and the criteria, A2, is also a number,
then you could use a single FREQUENCY call.

=INDEX(FREQUENCY('X:\y\[z.xls]Sheet1:Sheet2'!$A:$A,A2*
{0.999999999999999;1}),2)

FREQUENCY, unlike COUNTIF, does handle external references into closed
workbooks.
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
How do I use a countif function according to two other countif fu. Kirsty Excel Worksheet Functions 2 February 20th 06 11:44 AM
COUNTIF(--(),--()) help in '97 Adam Kroger Excel Discussion (Misc queries) 6 December 16th 05 12:09 PM
edit this =COUNTIF(A1:F16,"*1-2*")+COUNTIF(A1:F16,"*2-1*") sctroy Excel Discussion (Misc queries) 2 September 25th 05 04:13 AM
COUNTIF or not to COUNTIF on a range in another sheet Ellie Excel Worksheet Functions 4 September 15th 05 10:06 PM
COUNTIF in one colum then COUNTIF in another...??? JonnieP Excel Worksheet Functions 3 February 22nd 05 02:55 PM


All times are GMT +1. The time now is 03:49 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"