eAlchemist
Technical User
Please help! I can't figure out why this isn't working for me. Everytime I run this line, I get a "Run-time error '1004': Unable to set the FormulaArray property of the Range class". The formula works when I enter it by hand. What's up?
Thanks, Chris
Here is the line of code:
Worksheets(Sheet.Name).Range(formulaAddress).FormulaArray = formulaText
And the values for the items referenced:
?formulaAddress
D124
?Sheet.Name
GIRLS
?formulaText
IF(SUM(IF(RawData!$B$2:$B$14646=$A$1, IF(RawData!$C$2:$C$14646=$B118, IF(RawData!$D$2:$D$14646=$B124, IF(RawData!$E$2:$E$14646=$C124,IF(RawData!$F$2:$F$14646=D$1,RawData!$G$2:$G$14646,0),0),0),0),0))=0,D125,SUM(IF(RawData!$B$2:$B$14646=$A$1, IF(RawData!$C$2:$C$14646=$B118, IF(RawData!$D$2:$D$14646=$B124, IF(RawData!$E$2:$E$14646=$C124,IF(RawData!$F$2:$F$14646=D$1,RawData!$G$2:$G$14646,0),0),0),0),0)))
Thanks, Chris
Here is the line of code:
Worksheets(Sheet.Name).Range(formulaAddress).FormulaArray = formulaText
And the values for the items referenced:
?formulaAddress
D124
?Sheet.Name
GIRLS
?formulaText
IF(SUM(IF(RawData!$B$2:$B$14646=$A$1, IF(RawData!$C$2:$C$14646=$B118, IF(RawData!$D$2:$D$14646=$B124, IF(RawData!$E$2:$E$14646=$C124,IF(RawData!$F$2:$F$14646=D$1,RawData!$G$2:$G$14646,0),0),0),0),0))=0,D125,SUM(IF(RawData!$B$2:$B$14646=$A$1, IF(RawData!$C$2:$C$14646=$B118, IF(RawData!$D$2:$D$14646=$B124, IF(RawData!$E$2:$E$14646=$C124,IF(RawData!$F$2:$F$14646=D$1,RawData!$G$2:$G$14646,0),0),0),0),0)))