... now the formulas on the 'mda model weighting' sheet
are giving a ref error ...
First, a clarification that the above actually had *nothing* to do with the
previous issue(s) raised and resolved earlier in this thread. I've cleaned
up and reconstructed the formulas in the problem sheet as per below
(Corrected file sent to you)
Clean-up and reconstruction of formulas
in sheet: MDA Model Weighting
------------------------------------------
The vlookup range was adjusted to: $A$4:$J$39 instead of $A$4:$I$39
The col index ref "10" in the vlookup for "Value" was causing the #REF!
everywhere previously because it pointed to a non-existent range ($A$4:$I$39
is only 9 cols!)
To facilitate copying down of formulas and to suit the sheet structure where
you had sheetnames merged and straddling 3 cols from cols D to AV, INDIRECT
was used. Along the way there were a couple of inconsistencies in the
sheetname structure for some sheets which were found and cleaned up.
Extraction of the 3 col index refs for the Vlookup per group of 3 cols was
automated via using another nested vlookup which read the 3 col headers
within each group: No. of Shares (4), Value (10), and Portfolio Weighting
(6)
Example: ... VLOOKUP(D$2,MDA_1,2,0) ...
where MDA_1 is a named range referring to a table in a new sheet: Index
No. of Shares 4
Value 10
Portfolio Weighting 6
Reconstructed formulas for cols D to AV
------------------------------------------------------
Typical set of 3 cols, e.g.: cols D to F
D1 contained the sheetname, e.g.: A & E John Super
(D1 was merged over D1:F1)
D2:F2 contained the 3 col headers:
No. of Shares
Value
Portfolio Weighting
Formula placed in D3:
=IF(ISNA(VLOOKUP($A3,INDIRECT("'"&$D$1&"'!$A$4:$J$39"),VLOOKUP(D$2,MDA_1,2,0
),0)),"",VLOOKUP($A3,INDIRECT("'"&$D$1&"'!$A$4:$J$39"),VLOOKUP(D$2,MDA_1,2,0
),0))
D3 was copied across 3 cols to F3
D3:F3 was then selected and copied for each successive set of 3 cols to the
right, to G3:I3, J3:L3, ... AT3:AV3 etc, and Edit > Replace used to replace
the $D$1 to $G$1, $J$1 ... etc
D3:AV3 could then be selected and copied down to AV47