A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » Worksheet Functions
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

SUMIF used in a link



 
 
Thread Tools Display Modes
  #1  
Old November 17th, 2003, 08:45 PM
Nat
external usenet poster
 
Posts: n/a
Default SUMIF used in a link

Hello,
I have a destination file where I'm using a SUMIF function
referencing the source data saved in another workbook.
When both files (the destination file with the SUMIF and
the source file are opened) I see the results of the SUMIF
calculations displayed. When I open only a destination
file, I'm prompted to "Update Links" or "Do not Update"
the links. If either option ('Update" or "Do not Update")
is chosen the file opens but the results of the
calculations are displayed as #VALUE error.

Any idea why it is happening? It doesn't happen if I use
a different function like VLOOKUP or SUM (I mean the
results of the calculations are displayed when "Do not
Update" option is chosen). Is it a limitation of the
SUMIF function (because it works if the source data is in
the same workbook but different worksheet)? Please help.
Thank you.

  #2  
Old November 17th, 2003, 09:02 PM
Harlan Grove
external usenet poster
 
Posts: n/a
Default SUMIF used in a link

"Nat" wrote...
I have a destination file where I'm using a SUMIF function
referencing the source data saved in another workbook.
When both files (the destination file with the SUMIF and
the source file are opened) I see the results of the SUMIF
calculations displayed. When I open only a destination
file, I'm prompted to "Update Links" or "Do not Update"
the links. If either option ('Update" or "Do not Update")
is chosen the file opens but the results of the
calculations are displayed as #VALUE error.

Any idea why it is happening? It doesn't happen if I use
a different function like VLOOKUP or SUM (I mean the
results of the calculations are displayed when "Do not
Update" option is chosen). Is it a limitation of the
SUMIF function (because it works if the source data is in
the same workbook but different worksheet)? Please help.


SUMIF and COUNTIF *REQUIRE* that their 1st argument (and optional 3rd argument
for SUMIF) be range references. External link references are range references
only when the linked workbook is open; they're arrays when the linked workbook
is closed. Since SUMIF and COUNTIF require range references, they choke on array
references to ranges in closed files.

Use SUMPRODUCT instead. For example, replace

SUMIF(X,"=Y"), COUNTIF(X,"Y") and SUMIF(X,"*Y*",Z)

with

SUMPRODUCT((X=Y)*X), SUMPRODUCT(--(XY)) and
SUMPRODUCT(ISNUMBER(SEARCH(Y,X)*Z), respectively.

--
Never attach files.
Snip unnecessary quoted text.
Never multipost (though crossposting is usually OK).
Don't change subject lines because it corrupts Google newsgroup archives.
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 04:49 PM.


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