cassidybklyn
Programmer
Hello everyone,
I am working with VB6. I have a module that counts unique items in a spreadsheet. In the same spreadsheet, I want to sum a column that has Currency.
The count function works okay, but when I try to sum the column that has the dollar value, it overrides the count. In otherwords, the xlsum function replaces the xlcount function.
How can I retain my count and at the same time sum the currency value column?
Below is my code:
With xlApp
.Selection.Subtotal GroupBy:=7, TotalList:=Array(7), PageBreaks:=True, Function:=xlCount, SummaryBelowData:=True
.Selection.Subtotal TotalList:=Array(4),Function:=xlSum, SummaryBelowData:=True
End With
Thanks.
Cassidy
I am working with VB6. I have a module that counts unique items in a spreadsheet. In the same spreadsheet, I want to sum a column that has Currency.
The count function works okay, but when I try to sum the column that has the dollar value, it overrides the count. In otherwords, the xlsum function replaces the xlcount function.
How can I retain my count and at the same time sum the currency value column?
Below is my code:
With xlApp
.Selection.Subtotal GroupBy:=7, TotalList:=Array(7), PageBreaks:=True, Function:=xlCount, SummaryBelowData:=True
.Selection.Subtotal TotalList:=Array(4),Function:=xlSum, SummaryBelowData:=True
End With
Thanks.
Cassidy