Getting data labels right....

4

43fan

I have an XY Scatter chart plotting two columns of data. The data labels I
want to use for the points on the chart are in a third column, each row
corresponding to the proper row for the data being plotted.

How do I get the data labels to display the values in the third column?

Thanks!
Shawn
 
J

John Mansfield

43fan,

These resources will help:

(1) You can use Rob Bovey's XY Chart Labeler add-in located at:

http://www.appspro.com/Utilities/ChartLabeler.htm

(2) You can use John Walkenbach's Chart Tools add-in located at:

http://j-walk.com/ss/excel/files/charttools.htm

(3) You can use the following macro (load in a standard module):

Sub AddLabels()
Dim RngLabels As Range
Dim Ser As Series
Dim i As Long
If TypeName(Selection) = "Series" Then
Set Ser = Selection
Set RngLabels = Application.InputBox(prompt:="Select the label
range:", Type:=8)
Ser.HasDataLabels = True
For i = 1 To Ser.Points.Count
Ser.Points(i).DataLabel.Text = RngLabels(i)
Next i
Else
MsgBox "Select a series in a chart."
End If
End Sub

In the dialog box, add the reference to the data source like "Sheet1!A1:A5".

(4) You can use the techniques described here:

http://www.pdbook.com/index.php/excel/auto_update_xy_chart_with_independent_data_labels/
 

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