Forum Discussion
BlueCollarVending
Oct 11, 2023Copper Contributor
conditional formatting
Hello. So I wanted to know if there was a way to have my totals column deduct an amount if it has a conditional formatting met?
Ex; I have a expense report that has business purchases and at the bottom I have the totals. On the side I have a return column (for items I've returned). I have a conditional format that states "if a "yes" is selected on the returns column, then it changes the color of the text and puts a strike through on the line. BUT what i would like to add is for the items that are being "returned" to have that amount DEDUCTED from the totals at the bottom automatically as well as have that "returned" amount added to a another totals column.
I understand that there are multiple formulas at play here. I need a place to start.
1. have to have the totals column reference the returns column
2. need to decided if it meets a criteria, return "yes" or "no"
3. if it meets the "yes" then it will deduct the amount of that row from the totals
4. then it will take that "deducted amount and add to a different totals box (which im assuming the formula for that would need to be in the "returns total" box and would reference the "returns" and the "totals")
If there is anyone that could at least help get me pointed in the right direction, that would be appreciated.
thanks
- first off are you talking about a spreadsheet of data, a defined table, a pivot table or something else? If it is just a spreadsheet of data and you have a formula at the bottom something like =SUM(J2:J100) then probably something like this will work:
=SUM(J2:J100) - SUMIFS(J2:J100, B2:B100, "yes")
- mtarlerSilver Contributorfirst off are you talking about a spreadsheet of data, a defined table, a pivot table or something else? If it is just a spreadsheet of data and you have a formula at the bottom something like =SUM(J2:J100) then probably something like this will work:
=SUM(J2:J100) - SUMIFS(J2:J100, B2:B100, "yes")- BlueCollarVendingCopper ContributorThat worked beautifully. Thank you. It took a minute to figure out where to put the formula but after that, Amazing.