Hi All,
I have a spreadsheet representing a month where I am trying to figure out different scenarios for employees. One scenario is that an employee could have to move to a temporary position. In that case, I need to calculate the salary payments to temporary employees in a particular work unit. I've tried several different approaches to this problem, but am still getting the error.
One method has been using this sumproduct formula:
The data in column AA is formatted as currency. The formula results in an error stating that a "value used in this formula is of the wrong data type"Code:=SUMPRODUCT($P24:$P207="Temp")*($Q$24:$Q$207="A/R")*($AA$24:$AA$207)
A different sumproduct formula is used for temps that may be employed in an administrative role:
That results in the same error as indicated previouslyCode:=SUMPRODUCT(--($P$24:$P$207="Temp"),--ISNUMBER(SEARCH("Admin",$Q$24:$Q$207))*($AA$24:$AA$207))
Finally, I've tried an array formula as well:
That results in "wrong data type error" as well.Code:=SUM(($P$24:$P$207="Temp")*($Q$24:$Q$207="BSG")*($AA$24:$AA$207))
Any ideas? I would guess the problem lay with the data in column AA, but I've tried it as both currency and number data format and neither has worked. Oddly enough, a simple Sumif formula, using the data in column AA seems to work, but an if(sumif( formula does not.
I've attached a sample spreadsheet. The formulas I'm having problems with begin in L302.
Thanks in advance for the help
Cheers,
Tim
Last edited by judasdac; 07-16-2009 at 01:38 PM.
I would remove the multiplication ("*") and stick with individual arguments e.g.Does that work for you?Code:=SUMPRODUCT(--($P24:$P207="Temp"),--($Q$24:$Q$207="A/R"),($AA$24:$AA$207)) =SUMPRODUCT(--($P$24:$P$207="Temp"),--ISNUMBER(SEARCH("Admin",$Q$24:$Q$207)),($AA$24:$AA$207))
ChemistB
My 2¢
Don't forget to mark threads as "Solved" (Edit First post>Advanced>Change Prefix)
If I helped, Don't forget to add to my reputation (click on the little star at bottom of this post)
I never considered that could be the problem. It works perfectly! Thanks for the assist ChemistB
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks