Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
hfkchristian
Creator
Creator

Change the look of a gauge chart

Hi all

I try to make a macro to change the look of a gauge chart. I tried this, but it's nok working:

set chart = ActiveDocument.GetSheetObject("GaugeChart")
set prop = chart.GetProperties
prop.GaugeChartMode =0
chart.SetProperties prop

It generates an error on the line prop.gaugechartmode=0. Do you have any idea why it's not working?

1 Solution

Accepted Solutions
sebastianlettner
Partner - Creator
Partner - Creator

Hi,

this should work.

set chart = ActiveDocument.GetSheetObject("GaugeChart")

set prop = chart.GetProperties

set gProp = prop.ChartProperties

gProp.GaugeChartMode = 0

chart.SetProperties prop

Regards

Sebastian Lettner

View solution in original post

2 Replies
sebastianlettner
Partner - Creator
Partner - Creator

Hi,

this should work.

set chart = ActiveDocument.GetSheetObject("GaugeChart")

set prop = chart.GetProperties

set gProp = prop.ChartProperties

gProp.GaugeChartMode = 0

chart.SetProperties prop

Regards

Sebastian Lettner

hfkchristian
Creator
Creator
Author

This works like a charm. Thanks a lot