So basically - I have built a simple spreadsheet to display set prices at specific quantities for a supplier. I have added cells for the user to input different quantities between the set ones, for example, a price is set at 1000 in cell B20 and another for 1500 in B22. If I want to know what 1200 will cost I enter this into A21 using the formula set in B21 =(B22-B20)/(A22-A20)*(A21-A20)+B20.
Now this works perfectly fine but that means I have a custom quantity row in between each set quantity row due to the difference in prices not being universal. Obviously this looks rather messy and I'd like a much cleaner version.
From my knowledge should it not be possible to have a worksheet set up where I can just enter a quantity and it displays the price (using vlookup?).
My idea is a formula that works along these lines;
if cell value is great than (a) or less than(b) then ( subtract (acost) from (bcost) ) and divide by ( (b) minus (a)) then ( multiply cell value minus (a) ) plus (acost)
Sorry if this is badly explained, if I can make it any clearer please let me know!
Bookmarks