+ Reply to Thread
Results 1 to 2 of 2

Formatting calculated totals in a Pivot Table

  1. #1
    overcanyon
    Guest

    Formatting calculated totals in a Pivot Table

    My pivot table summarizes monetary values and totals these values with the
    auto -generated column total and row total. I have formatted the data values
    that are displayed but how can I apply the same formatting to the total
    column and total row?

    So my pivot table looks something like this (as in no dollar signs on the
    totals)
    Jan Feb Mar Total
    categoryA $10 $14 $25 49
    categoryB $15 $12 $18 45
    Total 25 26 43 94

    Anyone any ideas?

  2. #2
    overcanyon
    Guest

    RE: Formatting calculated totals in a Pivot Table

    Actually finally sussed a solution myself...

    It goes like this:

    ' Sets formatting for totals
    xlApp.ActiveSheet.PivotTables("Values").PivotSelect("'Column
    Grand Total'", Microsoft.Office.Interop.Excel.XlPTSelectionMode.xlDataOnly)
    xlApp.Selection.NumberFormatLocal = "$#,###,###,##0.00"

    ' Sets formatting for totals
    xlApp.ActiveSheet.PivotTables("Values").PivotSelect("'Row Grand
    Total'", Microsoft.Office.Interop.Excel.XlPTSelectionMode.xlDataOnly)
    xlApp.Selection.NumberFormatLocal = "$#,###,###,##0.00"




    "overcanyon" wrote:

    > My pivot table summarizes monetary values and totals these values with the
    > auto -generated column total and row total. I have formatted the data values
    > that are displayed but how can I apply the same formatting to the total
    > column and total row?
    >
    > So my pivot table looks something like this (as in no dollar signs on the
    > totals)
    > Jan Feb Mar Total
    > categoryA $10 $14 $25 49
    > categoryB $15 $12 $18 45
    > Total 25 26 43 94
    >
    > Anyone any ideas?


+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1