E
Excel_VBA_Newb
Okay, I will try to explain this as best I can. I have, essentially, a
bulleted list (WBS in Program Management term). I want to do a sum of all
rows based on the bulleted hierarchy.
For Example:
(1st Range: contains the headings: A, AA, AAA, B, BA, BAA, etc)
(2nd Range: contains the values to base the percentages off of)
Total
A - Percentage of Total
AA - Percentage of A
AAA - Percentage of AA
AAB - Percentage of AA
AAC - Percentage AA
AACA - Percentage of AAC
AB - Percentage of A
B - Percentage of Total
BA - Percentage of B
BAA - Percentage of BA
BAB - Percentage of BA
BABA - Percentage of BAB
etc. etc. etc
The hierarchy is never constant. The Bulleted item (A, B, etc) is held in
one Range, and the values are held in another. What would be the best way to
iterate through the range and determine how to perform the percentage
calculations? I would imaging doing a LEN on the bulleted item, but not quit
sure how to iterate through both ranges and keeps the second range in synch
during the for loop on the first.
Any help is appreciated!
bulleted list (WBS in Program Management term). I want to do a sum of all
rows based on the bulleted hierarchy.
For Example:
(1st Range: contains the headings: A, AA, AAA, B, BA, BAA, etc)
(2nd Range: contains the values to base the percentages off of)
Total
A - Percentage of Total
AA - Percentage of A
AAA - Percentage of AA
AAB - Percentage of AA
AAC - Percentage AA
AACA - Percentage of AAC
AB - Percentage of A
B - Percentage of Total
BA - Percentage of B
BAA - Percentage of BA
BAB - Percentage of BA
BABA - Percentage of BAB
etc. etc. etc
The hierarchy is never constant. The Bulleted item (A, B, etc) is held in
one Range, and the values are held in another. What would be the best way to
iterate through the range and determine how to perform the percentage
calculations? I would imaging doing a LEN on the bulleted item, but not quit
sure how to iterate through both ranges and keeps the second range in synch
during the for loop on the first.
Any help is appreciated!