[Last Call] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

I need an excel formula

Posted on 2011-10-05
4
Medium Priority
?
301 Views
Last Modified: 2012-05-12
I need an excel formula to correctly select the position pay amount when that position number is selected from the drop down on the Projects Tab. The pay amount information is on Sheet1.

I am currently using the following formual to calculate how much based on certain criteria:

=COUNTIF(B12:O12,"1")*500+COUNTIF(B12:O12,"1LM")*500+COUNTIF(B12:O12,"1LM")*Sheet1!$G$1+COUNTIF(B12:O12,"L")*Sheet1!$G$2+SUM(A12*Sheet1!$G$3).

Where the 500 is listed is where i need it to be dynamic and based upon what is selected on the drop down.

Ideas and suggestions are welcomed. Please see the attached.
10-5-11.xlsx
0
Comment
Question by:wrt1mea
4 Comments
 
LVL 50

Assisted Solution

by:Ingeborg Hawighorst (Microsoft MVP / EE MVE)
Ingeborg Hawighorst (Microsoft MVP / EE MVE) earned 1200 total points
ID: 36920290
Hello,

in your file the value for Position 5 is 104, so the result will be different from the formula with the 500 hard-wired.

=COUNTIF(B12:O12,"1")*VLOOKUP($H$5,Sheet1!$E$1:$F$15,2,FALSE)+COUNTIF(B12:O12,"1LM")*VLOOKUP($H$5,Sheet1!$E$1:$F$15,2,FALSE)+COUNTIF(B12:O12,"1LM")*Sheet1!$G$1+COUNTIF(B12:O12,"L")*Sheet1!$G$2+SUM(A12*Sheet1!$G$3)

cheers, teylyn
0
 
LVL 42

Expert Comment

by:dlmille
ID: 36920304
Try this:

=COUNTIF(B12:O12,"1")*VLOOKUP(H5,Sheet1!$E$1:$F$15,2,0)+COUNTIF(B12:O12,"1LM")*500+COUNTIF(B12:O12,"1LM")*Sheet1!$G$1+COUNTIF(B12:O12,"L")*Sheet1!$G$2+SUM(A12*Sheet1!$G$3)

The VLOOKUP is using the drop down value to seek a result on Sheet1 in E:F, and selecting the 2nd parameter (the amount) with 0-exact match.

Just extend E1:F15 down if more positions are required in future...

Dave
0
 
LVL 50

Accepted Solution

by:
barry houdini earned 800 total points
ID: 36920398
I assume both 500s are dynamic as per teylyn's version

a little simpler to SUM the COUNTIFS and multiply by the VLOOKUP then it doesn't need to repeat....also SUM at the end is redundant.....

=SUM(COUNTIF(B12:O12,{1,"1LM"}))*VLOOKUP($H$5,Sheet1!$E$1:$F$15,2,FALSE)+COUNTIF(B12:O12,"1LM")*Sheet1!$G$1+COUNTIF(B12:O12,"L")*Sheet1!$G$2+A12*Sheet1!$G$3

regards, barry
0
 
LVL 1

Author Closing Comment

by:wrt1mea
ID: 36920491
Works great! Thanks for the support!
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

You need to know the location of the Office templates folder, so that when you create new templates, they are saved to that location, and thus are available for selection when creating new documents.  The steps to find the Templates folder path are …
Windows Explorer let you handle zip folders nearly as any other folder: Copy, move, change, and delete, etc. In VBA you can also handle normal files and folders, but zip folders takes a little more - and that you'll find here.
The viewer will learn how to use the =DISCRINV command to create a discrete random variable, use this command to model a set of probabilities and outcomes in a Monte Carlo simulation, and learn how to find the standard deviation of a set of probabil…
Although Jacob Bernoulli (1654-1705) has been credited as the creator of "Binomial Distribution Table", Gottfried Leibniz (1646-1716) did his dissertation on the subject in 1666; Leibniz you may recall is the co-inventor of "Calculus" and beat Isaac…

834 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question