Formula Lookup

KirstAnn1

New Member
Joined
Jul 28, 2020
Messages
2
Office Version
  1. 365
Platform
  1. Windows
Hi,

I am creating a template for invoice creation. There are 300 pay items (pre quoted, and any number or combination can be used) and I have allowed a section for variations that happen ad-hoc.
All 300 pay items indivudially numbered, they all follow the same basic principal there is: (only exception is variations that all have item numbers ranging between 5000-5999 and they can have the same item number repeated based on the variation type, so I added area where they can be included then anything with that range of item number then has to be referenced into that section via text matching provided in a drop down list, kinda messy but I've tried my best) but neverthe less they follow the same convention of:
-UOM 1(unit of measure)
-rate 1
-qty used 1
-UOM 2
-rate 2
-qty used 2

To determine cost some pay items are simply (rate 1 X qty used 1) + (rate 2 X qty used 2) but others are (((qty 2 X rate 2) + rate 1) X qty 1) and others simply only have rate 1, UOM 1 and quantitiy 1

My problem is how to tell the "total" cell what "formula" to use based off the item number

Not sure if importiant but all cells here come from an input sheet in the same workbook so I was able to allow for the variations to come through

I have tried to go down the VLOOKUP pathway to then have the correct "formula" located next to the master pay item list and tried to use the OFFSET to then base off the refernce cell but with the variations, it was getting too lost in the formula so then tried to place this in the input sheet but again I was getting errors.

Also I am writing everything in formula, as no one else in the office can use VBA, so makes sense that if anyone else ever needs to change then they can follow a touch easier.

Thanks
 

Attachments

  • Excell.PNG
    Excell.PNG
    22.1 KB · Views: 6

Excel Facts

Whats the difference between CONCAT and CONCATENATE?
The newer CONCAT function can reference a range of cells. =CONCATENATE(A1,A2,A3,A4,A5) becomes =CONCAT(A1:A5)
Hi KirstAnn1,

It's difficult to follow your question but I think you're saying you have three different formats of items and you've used VLOOKUP to construct most columns of your invoice template but are unsure how to perform the different types of Total calculations?

If you are driven by data from another sheet then I assume that sheet has some kind of indication as to which of the three types an item is. In this example I'm using the first 8 rows as the Item data (to keep it simple) and the CHOOSE statement to retrieve the calculation type for each of 3 types. Maybe this will give you an idea on how to move forward.

Book1
ABCDEFGHIJKLMNO
1ItemCalc
255551
32222
47773
5
6
7
8
9
10DateItemDescriiptionEst Qty 1Unit 1Actual Qty 1Rate 1Est Qty 2Units 2Actual Qty 2Rate 2Total
117/7/20205555Widget10tonnes10$200.00254$100.00$2,400.00
125/12/2020222Stuff1shift5$4,600.001n-shift3$5,060.00$98,900.00
134/4/2020777Brinch Gasket22123$250.00$9,000.00
14 
Sheet1
Cell Formulas
RangeFormula
O11:O14O11=IFERROR(CHOOSE(VLOOKUP(B11,$B$2:$C$8,2,0),(((I11*J11)+(M11*N11))),(((M11*N11)+J11)*I11),((J11*I11*H11))),"")
 
Upvote 0
Yes you got your assumptions correct in what I was trying to look up.

Apologies for my bad explination.

Your formula looks great and from reading should work as needed. I will spend some time and get it into the spreadsheet but thankyou so much! It really helps. I hadnt though of placing the formula in that way to solve it, I knew I needed to nest it in someway just didnt know what and how. So thank-you again :)
 
Upvote 0
Phew! Glad I got close.
You're welcome and thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,215,758
Messages
6,126,697
Members
449,331
Latest member
smckenzie2016

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top