![multiple subtotals in excel multiple subtotals in excel](https://cdn.ablebits.com/_img-blog/more-excel-subtotals/add-new-column.jpg)
Though if I click on level of detail 2, I see the Dept 1 Total and the Y Total for Dept 2 instead of seeing both Dept Subtotals. Currently I have 4 levels of detail indicators 4) all detail, 3) all subtotals, 2) Dept subtotals, 1) Grand Total only. The subtotal 2 Total should be below the subtotal Y total, and the "show level of detail indicators need to match up correctly. Here is a partial view of one of the worksheets that is having the issue: The onlyĭifference on these 2 tabs is that there are fewer total records (11 records vs. I have read that this might be the cause of the problem, however, all of the sheets in my workbook have this same condition of no "Y" values in the first dept. The first dept has no "Y" values in column B, therefore only shows a subtotal for "N". I need to get a subtotal of the "N"s and "Y"s for each dept.
![multiple subtotals in excel multiple subtotals in excel](https://d295c5dn8dhwru.cloudfront.net/wp-content/uploads/2019/05/14142548/Figure-2.-Final-result-How-to-insert-subtotals-in-Excel.png)
The second subtotal additionally applies a subtotal to column B. The first subtotal that I apply has 2 members: 2 different dept numbers (column A). The data is not exactly the same as the other sheets but there aren't any significant changes. I also tried doing a separte file with only those 2 sheets, and had the same problem.Ĭlearly, it must be something in the data, but I can't see what it could be. I change the sheet order to put the 2 problem sheets first, and they both still had the problem.
#Multiple subtotals in excel Pc#
I also tried to run the same thing on a PC that had Excel 2007, but I had the exact same result.Īny suggestions would be greatly appreciated. Since I have done that, what else can I do? Or how can I determine what is differentĪbout the 9th and 10th worksheets that cause the subtotals to behave differently for them? I have searched the web for a solution, but the only answer I have ever seen is to apply the service pack or to change the Registry settings to apply Excel 97 Subtotals. It also causes the show level of detail indicators to line up with the incorrect data.
![multiple subtotals in excel multiple subtotals in excel](https://www.myexcelonline.com/wp-content/uploads/2021/11/Report-Filter-Layout-2.png)
It works fine for the first 8 worksheets, but not for the 9th or 10th.
#Multiple subtotals in excel code#
I am programatically exporting the data from Access 2002 using VBA code to create the Excel file, and usingĪ loop to apply the same subtotals to all worksheets. I have long ago done the registry changes to use the Excel 97 Subtotals function, and haven't had a problem prior to this. After the subtotals are placed correctly below the data for the first 8 worksheets, on the 9th and 10th worksheets, the subtotals of the bottom section appear I am using Excel 2002 and trying to add 2 levels of subtotals to multiple worksheets in a workbook.