Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a workbook containing several worksheets, I wish to perform a subtotal
on each worksheet. Each worksheet is setup identical in terms of the number of columns and colum titles etc but differ in the number of rows containing data. I am using the following code: For Each ws In ActiveWorkbook.Worksheets ws.Activate Range("A1").Select Range(Selection, Selection.End(xlToRight)).Select Range(Selection, Selection.End(xlDown)).Select Selection.Subtotal GroupBy:=10, Function:=xlSum, TotalList:=Array(13), _ Replace:=True, PageBreaks:=False, SummaryBelowData:=True Next I get an error message saying that saying: "Subtotal method Of Range class failed" Can anyone advise? -- K Hogwood-Thompson |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
sort macro, subtotal and add lines after subtotal | Excel Discussion (Misc queries) | |||
macro excel subtotal in subtotal | Excel Discussion (Misc queries) | |||
Worksheet subtotal | Excel Discussion (Misc queries) | |||
Subtotal - copy to other worksheet | Excel Programming | |||
Insert a new worksheet after subtotal | Excel Worksheet Functions |