If statements within Array formulas

MTBer

Board Regular
Joined
Apr 29, 2004
Messages
207
I'm putting together a crosstab report using an array formula, the formula is as follows

{=SUM(IF($A3&D$2&CC_Choice=HYP&date&CC,Amount))}

This basically produces a cost centre report for the Cost Centre Choice by account code by month.

I now wish to add an extra field of selection, by Business Unit, if a BU is selected a cost centre would not be selected so the CC-Choice field will be blank, and vice versa.

Is it possible to put an If statement into the above formula to determine if the report is by CC or BU.

My best attempt involves having a IF statement that checks if the field is populated and then runs the cc formula or bu formula,on the true false conditions.

thanks for your assistance.
 

Excel Facts

Add Bullets to Range
Select range. Press Ctrl+1. On Number tab, choose Custom. Type Alt+7 then space then @ sign (using 7 on numeric keypad)
"This basically produces a cost centre report for the Cost Centre Choice by account code by month"

wouldn't a pivot table be a more natural approach?

anyway, you need to describe you data set up in more detail - a worked example would help, as would a view of the data (you can post up a representative snapshot of your data with the html maker addin available by following the link below this post)
 
Upvote 0

Forum statistics

Threads
1,214,978
Messages
6,122,549
Members
449,089
Latest member
davidcom

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