Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hello All
I am using XP/Office2003 I am trying to sum columns (including blanks) with specific Headings. My headings are as follows starting in Column B, Row 4 Heading1, Heading2, Heading3,……..Heading11. Heading numbers will increase/decrease for various reports. In current report, I have recorded the following macro which sums Column Heading9 and 10 Sub Macro3 () Range("J45").Select ActiveCell.FormulaR1C1 = "=SUM(R[-40]C:R[-1]C)" ActiveWindow.SmallScroll Down:=0 Range("K45").Select ActiveCell.FormulaR1C1 = "=SUM(R[-40]C:R[-1]C)" ActiveWindow.SmallScroll Down:=12 End Sub The Heading names will change if there are fewer columns…but the text will be same always. I wish to have a macro which should look for the text eg “aaaa” and “bbbb” and sum these columns. Number of Rows will also vary. The macro should therefore look up for the text “aaaa” and “bbbb” in Row 4 headings and sum up these two columns (including blanks) Any help would be appreciated. TIA Rashid Khan |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Headings of columns now have numbers, need to change them to lette | Excel Worksheet Functions | |||
I want to get rid of columns with numbers as headings, how do I? | Excel Discussion (Misc queries) | |||
Hidden Columns and Row Headings | Excel Discussion (Misc queries) | |||
Repeating Columns Headings | Excel Discussion (Misc queries) | |||
How do center headings across columns in excel | Excel Worksheet Functions |