ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Excel Programming in VB (https://www.excelbanter.com/excel-programming/276558-excel-programming-vbulletin.html)

sapta

Excel Programming in VB
 
please try this
With .PivotFields("Next Quarter")
.Orientation =4
.Position = 7
.Function = xlSum ' for sum calculation
.NumberFormat = "#.##0" ' for format number
End With




-----Original Message-----
I have a code as follows in a VB Subroutine.

With .PivotFields("Next Quarter")
.Orientation =4
.Position = 7
End With

the problem is, the field "Next Quarter" is coming
as "Count of" field instead of "Sum of". So all the

values
in this field are distorted. How do I force this field
to "Sum of"? Any idea?

A quick reply is appreciable.

Thanks
Sugith

.



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

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