ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Sumproduct #N/A elminate? (https://www.excelbanter.com/excel-worksheet-functions/5463-sumproduct-n-elminate.html)

na

Sumproduct #N/A elminate?
 
I am using the following forumla:

=SUMPRODUCT(--(Sheet2!$D$2:$D$396DATE(2004,6,15)),--(Sheet2!$D$2:$D$396<=DATE(2004,7,15)),Sheet2!$G$2: $G$396)+SUMPRODUCT(--(Sheet2!$K$2:$K$396DATE(2004,6,15)),--(Sheet2!$K$2:$K$396<=DATE(2004,7,15)),Sheet2!$N$2: $N$396)

The question is: How do I omit cells within the range that have #N/A
(because data hasn't been entered in that cell to make the function work)?

Thanks

Frank Kabel

Hi
easiest way would be to change the formulas which creates the #NA. what
formula are you using in these cells

--
Regards
Frank Kabel
Frankfurt, Germany


na wrote:
I am using the following forumla:


=SUMPRODUCT(--(Sheet2!$D$2:$D$396DATE(2004,6,15)),--(Sheet2!$D$2:$D$39
6<=DATE(2004,7,15)),Sheet2!$G$2:$G$396)+SUMPRODUCT (--(Sheet2!$K$2:$K$39
6DATE(2004,6,15)),--(Sheet2!$K$2:$K$396<=DATE(2004,7,15)),Sheet2!$N$2:
$N$396)

The question is: How do I omit cells within the range that have #N/A
(because data hasn't been entered in that cell to make the function
work)?

Thanks



na

In the first sumproduct Column G has the following:
=E40*(VLOOKUP(F40,Airfare,2,FALSE))

in the second sum product columan N has: =VLOOKUP(M2,Airfare,3,False)

"Frank Kabel" wrote:

Hi
easiest way would be to change the formulas which creates the #NA. what
formula are you using in these cells

--
Regards
Frank Kabel
Frankfurt, Germany


na wrote:
I am using the following forumla:


=SUMPRODUCT(--(Sheet2!$D$2:$D$396DATE(2004,6,15)),--(Sheet2!$D$2:$D$39
6<=DATE(2004,7,15)),Sheet2!$G$2:$G$396)+SUMPRODUCT (--(Sheet2!$K$2:$K$39
6DATE(2004,6,15)),--(Sheet2!$K$2:$K$396<=DATE(2004,7,15)),Sheet2!$N$2:
$N$396)

The question is: How do I omit cells within the range that have #N/A
(because data hasn't been entered in that cell to make the function
work)?

Thanks




Aladin Akyurek


na Wrote:
In the first sumproduct Column G has the following:
=E40*(VLOOKUP(F40,Airfare,2,FALSE))

in the second sum product columan N has:
=VLOOKUP(M2,Airfare,3,False)...


If Airfare is sorted on its first column, use the faster:

=E40*IF(VLOOKUP(F40,Airfare,1,1)=F40,VLOOKUP(F40,A irfare,2,1),0)

Otherwise, you have to resort to costly...

=E40*IF(ISNA(VLOOKUP(F40,Airfare,2,FALSE)),0,VLOOK UP(F40,Airfare,2,FALSE))


--
Aladin Akyurek
------------------------------------------------------------------------
Aladin Akyurek's Profile: http://www.excelforum.com/member.php...fo&userid=4165
View this thread: http://www.excelforum.com/showthread...hreadid=274352


na

Thanks - the second one worked for me!

"Aladin Akyurek" wrote:


na Wrote:
In the first sumproduct Column G has the following:
=E40*(VLOOKUP(F40,Airfare,2,FALSE))

in the second sum product columan N has:
=VLOOKUP(M2,Airfare,3,False)...


If Airfare is sorted on its first column, use the faster:

=E40*IF(VLOOKUP(F40,Airfare,1,1)=F40,VLOOKUP(F40,A irfare,2,1),0)

Otherwise, you have to resort to costly...

=E40*IF(ISNA(VLOOKUP(F40,Airfare,2,FALSE)),0,VLOOK UP(F40,Airfare,2,FALSE))


--
Aladin Akyurek
------------------------------------------------------------------------
Aladin Akyurek's Profile: http://www.excelforum.com/member.php...fo&userid=4165
View this thread: http://www.excelforum.com/showthread...hreadid=274352




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

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com