How to change chart data lables in PowerPoint by using VBA (without changing the actual values)

luckyluke

New Member
Joined
Feb 13, 2015
Messages
4
Hi everybody,

I would like to ask you for help in the following case. I have an Excel macro that changes data labels for one particular chart without changing the actual values (the code in the blue below).

select_all_icon.jpg
page_white_copy.png

<code style="margin: 0px; padding: 0px; font-style: inherit; font-weight: inherit;">

.
.
.

ActiveSheet.ChartObjects("Chart 4").Activate
ActiveChart.SeriesCollection(1).Values = Range("wf_V").Resize(waterfall_count, 1)
ActiveChart.SeriesCollection(2).Values = Range("wf_U").Resize(waterfall_count, 1)
ActiveChart.SeriesCollection(3).Values = Range("wf_X").Resize(waterfall_count, 1)
ActiveChart.SeriesCollection(4).Values = Range("wf_W").Resize(waterfall_count, 1)
ActiveChart.SeriesCollection(5).Values = Range("wf_Y").Resize(waterfall_count, 1)
ActiveChart.SeriesCollection(6).Values = Range("wf_Z").Resize(waterfall_count, 1)
ActiveChart.SeriesCollection(1).XValues = Range("label_start").Resize(waterfall_count, 1)
ActiveChart.SeriesCollection(2).XValues = Range("label_start").Resize(waterfall_count, 1)
ActiveChart.SeriesCollection(3).XValues = Range("label_start").Resize(waterfall_count, 1)
ActiveChart.SeriesCollection(4).XValues = Range("label_start").Resize(waterfall_count, 1)
ActiveChart.SeriesCollection(5).XValues = Range("label_start").Resize(waterfall_count, 1)
ActiveChart.SeriesCollection(6).XValues = Range("label_start").Resize(waterfall_count, 1)




For Counter = 1 To waterfall_count
ActiveChart.SeriesCollection(1).Points(Counter).HasDataLabel = True
ValueLabel = Round(Sheets("Aux").Range("val_lab_start").Offset(Counter - 1, 0).Value)
ActiveChart.SeriesCollection(1).Points(Counter).DataLabel.Text = ValueLabel
Next Counter
ActiveChart.SeriesCollection(1).DataLabels.Select
Selection.Position = xlLabelPositionInsideBase


.
.
.</code>

The problem is that I would need to reproduce the same action in PowerPoint, that seems to require different coding. Would any of you had the idea how to fix this issue?

Thank you for any answer or any data source for getting better PowerPoint VBA programming!
 

Excel Facts

Using Function Arguments with nested formulas
If writing INDEX in Func. Arguments, type MATCH(. Use the mouse to click inside MATCH in the formula bar. Dialog switches to MATCH.

Forum statistics

Threads
1,214,875
Messages
6,122,046
Members
449,063
Latest member
ak94

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top