Pivot chart formats

K

kate

I would like to know how to keep my formats on an excel pivot chart, I have
read the help on vba and opened up view code but I am unsure of what code
goes in next ??? there does not seem to be any examples anywhere

please help
 
D

Debra Dalgleish

You can record a macro as you format the pivot chart.
Then, assuming the chart is on a chart sheet --
Right-click on the chart sheet tab, and choose View Code
From the dropdown list at the top left, choose Chart
From the dropdown list at the top right, choose Calculate
Paste your code where the cursor is flashing, e.g.:

Private Sub Chart_Calculate()
With ActiveChart.SeriesCollection(3).Interior
.ColorIndex = 37
.Pattern = xlSolid
End With

End Sub

You may have to modify it a bit, but that should help you get started.
 
K

kate

Debra Dalgleish said:
You can record a macro as you format the pivot chart.
Then, assuming the chart is on a chart sheet --
Right-click on the chart sheet tab, and choose View Code
From the dropdown list at the top left, choose Chart
From the dropdown list at the top right, choose Calculate
Paste your code where the cursor is flashing, e.g.:

Private Sub Chart_Calculate()
With ActiveChart.SeriesCollection(3).Interior
.ColorIndex = 37
.Pattern = xlSolid
End With

End Sub

You may have to modify it a bit, but that should help you get started.



--
Debra Dalgleish
Contextures
http://www.contextures.com/tiptech.html
thankyou for your help its appreciated
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top