Consolidating switch formula

andrewb90

Well-known Member
Joined
Dec 16, 2009
Messages
1,077
Hello all,

I have a shortened version of my formula, and I wanted to see if anybody had an easier way of doing this. I've got another 30 rows to add to the formula, and I haven't had much luck doing a range.

Code:
=(SWITCH(J3,"GONE!",D3,0))+(SWITCH(J4,"GONE!",D4,0))+(SWITCH(J5,"GONE!",D5,0))+(SWITCH(J6,"GONE!",D6,0))+(SWITCH(J7,"GONE!",D7,0))+(SWITCH(J8,"GONE!",D8,0))+(SWITCH(J9,"GONE!",D9,0))

To clarify the formula, Column D has dollar amounts, and J has time formulas which at a certain time, will change to value "GONE!" I need to sum up the values of all those that are "gone"
 

Excel Facts

Repeat Last Command
Pressing F4 adds dollar signs when editing a formula. When not editing, F4 repeats last command.

Forum statistics

Threads
1,215,446
Messages
6,124,904
Members
449,194
Latest member
JayEggleton

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