Formula or VBA to increase a cell value based off another cell.

Flexi1

New Member
Joined
Feb 15, 2015
Messages
15
Hi

I need some help and I hope I am explaining this correctly, I have attached a photo of my spreadsheet and I need
to increase the value of column (M) so that each value has a minimum profit of 2.50

Column (M) is determined by column (I) so I need something that will adjust column (I) until the value
in column (M) reaches 2.50.

Any figures in column (M) that are above 2.50 need to be skipped as they are already good.

Basically I need the sale price in column (I) to increase so that the profit is a min of 2.50 on all items that currently fall below that amount, the full spreadsheet has 100,00 rows
( Column (I) and (M) have formulas already applied to get their totals, not sure if that matters)
 

Attachments

  • RALA SAMPLE SPREADSHEET.JPG
    RALA SAMPLE SPREADSHEET.JPG
    83.6 KB · Views: 4
Sorry I see what has happened there, I was meant to remove the formula for that column when I created the spreadsheet to upload here, looks like I forgot. The figure in (I) isn't meant to have the formula in there.
But don't columns G and H need to add up to column I?
If that is the case, then it is probably column G or H that need to be updated.
But which one?
 
Upvote 0

Excel Facts

Can you sort left to right?
To sort left-to-right, use the Sort dialog box. Click Options. Choose "Sort left to right"
But don't columns G and H need to add up to column I?
If that is the case, then it is probably column G or H that need to be updated.
But which one?
It would be the markup that would need changing, the markup dictates the sale price. The purchase price plus the markup equals the sale price.
 
Upvote 0
My 2 cents, I would add some columns so you can have some flexibility on the Target Profit (My column O). If you are happy with the results in P, then you can copy that column and Paste Special - Values back into I. And I threw in some conditional formatting on the Profit column so you can see which ones fall below the target. This method lets you preview the changes that will be made before you replace the existing data.
(I had created the data and formulas from your first picture so my column headings are messed up. I changed data in G and H to test different results.)

Book1
ABCDEFGHIJKLMNOPQ
1priceprofitTarget ProfitUpdated Sale Price Updated Profit
27620B7620BBLAC1112instock6.351.273.697.621219.622.942.9433.9242.192.5019.932.50
37620Bqwertyinstock6.351.273.697.621320.622.942.9433.9243.1920.623.19
47620Basdfghinstock6.351.273.6981018.002.942.9433.9240.1920.312.50
Sheet1
Cell Formulas
RangeFormula
P2:P4P2=IF(M2<$O$2,($O$2-M2)+I2,I2)
Q2:Q4Q2=P2-L2-K2-J2-G2
Cells with Conditional Formatting
CellConditionCell FormatStop If True
M2:M4Expression=M2<$O$2textNO
Hi, thanks for this, the problem I get is that when I input the new sale price, as the prices increase so do the costs so then the profit falls below the threshold of 2.5 again
 
Upvote 0
If you put this formula in cell H2, it seems to return the desired value of 2.50 in cell M2:
Excel Formula:
=G2+5
 
Upvote 0

Forum statistics

Threads
1,215,096
Messages
6,123,074
Members
449,093
Latest member
ripvw

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