ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Charts and Charting in Excel (https://www.excelbanter.com/charts-charting-excel/)
-   -   Getting data labels right.... (https://www.excelbanter.com/charts-charting-excel/18238-getting-data-labels-right.html)

43fan

Getting data labels right....
 
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



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 he

http://www.pdbook.com/index.php/exce...t_data_labels/

----
Regards,
John Mansfield
http://www.pdbook.com



"43fan" wrote:

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





All times are GMT +1. The time now is 10:11 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com