Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Consolidation Function VBA
Dose anyone know how to simplify this function??
I have to write the function 8 times (consolidation 8 seperate areas on a spreadsheet) the only parts that change are the sheet numbers and the consolidation area. Example: all sheets consolidated for Q1, 3 sheets for Q2, ect.... I hoping to be able to have the array that's being created be dynamic based on information located in a specified worksheet. thanks in advance Selection.Consolidate Sources:=Array( _ "'" & ThisWorkbook.Path & "\[" & ThisWorkbook.Name & "]" & Sheet38.Name & "'!" & Q3_Area, _ "'" & ThisWorkbook.Path & "\[" & ThisWorkbook.Name & "]" & Sheet36.Name & "'!" & Q3_Area, _ "'" & ThisWorkbook.Path & "\[" & ThisWorkbook.Name & "]" & Sheet37.Name & "'!" & Q3_Area, _ "'" & ThisWorkbook.Path & "\[" & ThisWorkbook.Name & "]" & Sheet34.Name & "'!" & Q3_Area, _ "'" & ThisWorkbook.Path & "\[" & ThisWorkbook.Name & "]" & Sheet31.Name & "'!" & Q3_Area, _ "'" & ThisWorkbook.Path & "\[" & ThisWorkbook.Name & "]" & Sheet35.Name & "'!" & Q3_Area, _ "'" & ThisWorkbook.Path & "\[" & ThisWorkbook.Name & "]" & Sheet25.Name & "'!" & Q3_Area, _ "'" & ThisWorkbook.Path & "\[" & ThisWorkbook.Name & "]" & Sheet28.Name & "'!" & Q3_Area), _ Function:=xlSum, TopRow:=False, LeftColumn:=False, CreateLinks:=False -- Helping Is always a good thing |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Using Consolidation function | Excel Programming | |||
consolidation | Excel Discussion (Misc queries) | |||
Consolidation | Excel Discussion (Misc queries) | |||
Product Function in Pivot Tables from Multiple Consolidation Range | Excel Worksheet Functions | |||
Consolidation | Excel Programming |