Access 2003 - PivotTable - How do you change the "Total Name" value in the properties of a Pivot Calculated Total

This should be a simple one, but for the life of me, I can't find how to change the "total name" property value in the advanced information section of a pivotTable's Calculated total property.

Basically I want it to be a little more descriptive than Total1
PivotTotalPropery.bmp
LVL 2
Cristal638Asked:
Who is Participating?
 
Cristal638Connect With a Mentor Author Commented:
Here's what I came up with...  I can't seem to find a way to change the name of an existing Calculated total, but if I programmatically create the calculated total I can name it what I want.

Sub Add_TotalTEST()
    Dim vwView As OWC10.PivotView
    Dim ptConstants
    Dim totNewTotal

    Set vwView = Forms(GetDefaultParam("ActiveForm")).PivotTable.ActiveView
    Set ptConstants = Forms(GetDefaultParam("ActiveForm")).PivotTable.Constants
   
    ' Add a new total named "TotalTest" to the current view.
    Set totNewTotal = vwView.AddTotal("TotalTest", vwView.FieldSets("Sales").Fields(0), ptConstants.plFunctionSum)
             
    ' Insert the newly created total into the detail area of the PivotTable.
    vwView.DataAxis.InsertTotal totNewTotal

End Sub
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.