ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Subtotal another open sheet in VBA (https://www.excelbanter.com/excel-programming/320823-subtotal-another-open-sheet-vba.html)

Jeff

Subtotal another open sheet in VBA
 
I am trying to use the worksheet function along with Subtotal to get the
total of a range on another sheet and place it in the main spreadsheet.

Cells(49, C) = Workbooks(WrkBk).Worksheets("Billable
FT").WorksheetFunction.Subtotal(9, xlRng)

Where XlRng is Range, WrkBk is a value from an array. If I remove the
worksheet and workbook references, it runs locally.


All times are GMT +1. The time now is 05:38 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com