View Single Post
  #2   Report Post  
Debra Dalgleish
 
Posts: n/a
Default

After you create the chart, turn on the macro recorder again
Select the chart, and choose ChartChart Options
On the Data Labels tab, check Values
Click OK
Turn off the macro recorder

In the recorded code, you'll see a line similar to this:

ActiveChart.ApplyDataLabels AutoText:=True, LegendKey:=False, _
HasLeaderLines:=False, ShowSeriesName:=False, _
ShowCategoryName:=False, _
ShowValue:=True, ShowPercentage:=False, ShowBubbleSize:=False


Copy that line and paste it in your original macro code, after the lines
of code that create the chart.

LizW wrote:
Hello,

I recorded a macro to create a bar chart - I checked the checkbox to add the
values. Stopped recording and showed me the chart with the values. If I run
the macro again, it does not display the value. What is the code I need to
always display the value?



--
Debra Dalgleish
Excel FAQ, Tips & Book List
http://www.contextures.com/tiptech.html