Actually, there is a function to add descriptive labels in Excel 2013: After you have created your XY Scatter Graph, selected X- and Y-values and clicked "Add Data Labels" (4:15 in this video), do the following: 1. Click on one point so that they are all highlighted 2. Right click on one of them (while all are highlighted), and click "Format Data Labels" 3. Under "Label Options" appearing on the right side (default), deselect "X Value" and "Y Value" 4. Select "Value From Cells" 5. Click on the button "Select Range" 6. Now, select the row containing data for your labels (for example the "items" column) 7. Voilà, you have custom labels with no coding needed.
Thank you so much!! I've been trying to figure out how to do this and no-one in my office knew the answer. But you did - and made my life so much easier! Thanks very much!
Sir, please share you mail id because I have prepared one Excel VBA programming for automatically send mail from Excel when due date reached.but email continues trigger after reach due date. I need to stop the mail in the VBA programming. Please support
Thank you Doug. Appreciate your time and effort to create this tutorial. I'm running Excel 2010, so the 7-step process posted by eivihnd is not available to me. But since I am running Excel 2010 this tutorial is a great help.
When you add the macro in VBA, you have to do it as "insert / module", otherwise it doesn't work. At least that fixed the problem for me. Thanks for the video!
Thanks so much for the video! This is exactly what I have been trying to do for days! Now, if I could only control the labels...meaning show and hiding based on what I am sorting...
Hi Doug Many thanks for this video. I managed to add labels for the first time with them all aligned properly. I did find a couple of issues with filtering data and the code was then mis-aligned. But as I said managed it for the first time with my usual Excel jiggery pokery, thanks again.
Thanks a lot Doug H! It saved my dissertation thesis graphs! FYI, the macro code I took from the link you give here didn't work. I used this one instead: Sub AttachLabelsToPoints() 'Dimension variables. Dim Counter As Integer, ChartName As String, xVals As String ' Disable screen updating while the subroutine is run. Application.ScreenUpdating = False 'Store the formula for the first series in "xVals". xVals = ActiveChart.SeriesCollection(1).Formula 'Extract the range for the data from xVals. xVals = Mid(xVals, InStr(InStr(xVals, ","), xVals, _ Mid(Left(xVals, InStr(xVals, "!") - 1), 9))) xVals = Left(xVals, InStr(InStr(xVals, "!"), xVals, ",") - 1) Do While Left(xVals, 1) = "," xVals = Mid(xVals, 2) Loop 'Attach a label to each data point in the chart. For Counter = 1 To Range(xVals).Cells.Count ActiveChart.SeriesCollection(1).Points(Counter).HasDataLabel = _ True ActiveChart.SeriesCollection(1).Points(Counter).DataLabel.Text = _ Range(xVals).Cells(Counter, 1).Offset(0, -1).Value Next Counter End Sub
Thank you very much. Very helpful! May be relevant to highlight that your excel file should allow macros. Sometimes it is not the case by default. Hence when saving the macro you receive a warning and you should click on "no" and choose a macro-enabled excel format. I wasted a hour because of that
Hi Doug H, I think it would be best if you posted the solution from eivihnd into the summary. This would have saved me a lot of time If I knew ahead of time when reading the summary, "IF YOU HAVE EXCEL 2013 just read the steps below" Actually, there is a function to add descriptive labels in Excel 2013: After you have created your XY Scatter Graph, selected X- and Y-values and clicked "Add Data Labels" (4:15 in this video), do the following: 1. Click on one point so that they are all highlighted 2. Right click on one of them (while all are highlighted), and click "Format Data Labels" 3. Under "Label Options" appearing on the right side (default), deselect "X Value" and "Y Value" 4. Select "Value From Cells" 5. Click on the button "Select Range" 6. Now, select the row containing data for your labels (for example the "items" column) 7. Voilà, you have custom labels with no coding needed. Thanks, -Jeremy
And then sum? Do you know how to automatically adjust the min and max for the x and y axis based off the min and max of the data selected? This way u only see the grid where my points are and not from 0?
Hi Doug, Great video and it helped me a lot. The problem I am facing is that there are a lot of data points on the scatter plot which make data labels overlap and it gets difficult to identify. Is there a way to remove the data labels and only show them when we hover over the data point? Thanks!
Thanks, Doug! My scatter has hundreds of points with dense concentrations in areas; the labels appear per your instructional, but are cluttered and cannot be read/presented. Any idea on how to do this, so that when you hover your mouse, the label appears ala a standard chart with auto labels?
Hey I just want to say that there is a much easier way: 1. Block all your data 2. Create a scatter plot graph 3. Add chart element and add data labels 4. Right click on the label, click on "Format Data Labels" 5. Tick "Value From Cells" and select the range of names that you want TIPS: I once cannot find "Value From Cells" check mark, then I found out that we must confirm that the Excel you're running is not on "Compatibility Mode". How do you know that your Excel is running on compatibility mode or not? Look at your Excel top window. If there is "[Compatibility Mode]", then you will never find the "Value From Cells" check mark. The simplest way to fix this is just create a new Excel book, copy all your data needed from the past Excel book and paste it to the Excel book that is not running on compatibility mode, then do step 1-5 again.
Thanks this really helped. But my labels have very long names. So if I just want each label to have a separate symbol/colour in the graph and then have the labels to appear as legends at the side, how do I do that? I have 14 such labels.
maybe something like this ruclips.net/video/sNQxUTs6lJA/видео.html can give an idea. It'll need to be combined with a change in the series name to reflect the label name.
Simpler code: Sub Macro1() ActiveSheet.ChartObjects("Chart 1").Activate '1 chart number For i = 1 To 3 '3 is the total number of points ActiveChart.FullSeriesCollection(1).Select ActiveChart.FullSeriesCollection(1).DataLabels.Select ActiveChart.FullSeriesCollection(1).Points(i).DataLabel.Select Selection.Formula = Cells(7 + i - 1, 3).Value Next i Range("A1").Select End Sub
Hi Doug - great presentation and thank you very much - this was very helpful. Recently we needed to edit/change the label value. So we changed the label name in the Excel column, but the graph did not automatically update to reflect the new value. How do we do this so it's automatic and we don't have to do the whole thing over?
if you've got Excel 2013, you can actually put labels without any VBA. See video at ruclips.net/video/NnoFXSFBtIg/видео.html If you don't you'll have to do it over again :-(
***** hi Doug! i found sth else in this case. it is called "XY chart Label". i downloaded it for free also: [ www.appspro.com/Utilities/ChartLabeler.htm] it is very useful for those people who wanna labeling a lot of different data.
Excel 2013 - I am trying to show results of two measurements (y is measurement one, x is measurement 2), each unit of measure is minutes spent playing video games. The x data is what my observer recorded (number of minutes each child spent playing video games, 20 children total). Y data is what observer 2 recorded (in minutes for each child spent playing video games). So - my coders viewed video tapes of areas in which children spent time playing video games. [interrater reliability] - and I want to show this in a scatterplot in which the first set of data (y) and the second set of data (x) are on the same scatter chart - but I get to the part in your video in which you manually add the chart (7:22) and my spreadsheet does not appear the same - my chart styles look completely different. Do I need to customize or add something to my access tools? Thanks - sorry if this totally confuses you - I'm totally stuck on this!
Soo you can have the series name display the data label value, but I had to add each point individually. In 2013, I have to add each data point individually in the select data box. Once the point is in, I add the data label, in the data label I select the series name, and x value option and in my case, I enter a new line. I use the scatter chart to make milestone across a range of dates. In 2016 it did it just fine. It pulls the series name as the data label, the x values is a date in my data and the y value is the vertical position. My extra layer is it all has to show in office 365 so our employees can access the graph on their phones.
Thank you so much for sharing, Doug. But is it only me that I googled more than 3 pieces of code and none of them work or it's the same with other ppl?
Dear Doug: your video helped me a lot. Thanks. My scatter plot has different legends(e.g. It has 2 series), then the code cannot add labels, and give "Object variable or with block variable not set" error. Could you please help me on this? Thanks
For Excel 2013+ there is another possibility without the need for a macro. See here: exde601e.blogspot.de/2014/11/adding-labels-to-excel-scatter-charts.html
Thanks Doug. This works fine for me, but I'm having issues when I include more than one data series. In this instance, only the first data series is labelled when I run the macro. Do you have any advice?
James Haythornthwaite I managed to fix this - you need to change the series number in the brackets after any reference to "SeriesCollection" in the macro to then apply the macro to that specific series. Cheers
Hey Doug, I currently have an excel sheet with 3 series! All the data of the 3 series are in a sheet (DataSheet), and the chart is in separate worksheet loading the data from the datasheet. First of all would I need 3 different sheets for each series so i can apply the labels and does the chart need to be on the same sheet when loading the data? Also when I apply the macro, do I apply to the entire excel file, or on the sheets or on the tabs for this scenario! Thanks in advance!
+Doug H Well the client hasnt upgraded to 2013 which doesnt allow me to work on it! Why I say I have to put each series in a seperate sheet, because the code assumes that the first column contains the label and the other 2 columns contain values to load from!
What if I told you, I just I found a way that is not shown on the Internet and is far easier than yours but requires slight manual labor and no Macro!!!
H Doug - I have tried this macro, however it provides for an error. "xVals = Mid(xVals, InStr(InStr(xVals, ","), xVals, Mid(Left(xVals, InStr(xVals, ",") - 1), 9)))" I guess it pretty much has to do with the range that is being sellected. Please advise?
If you have Excel 2013 or later, there is a function to add descriptive labels you can actually put labels without any VBA. See video at ruclips.net/video/NnoFXSFBtIg/видео.html
Actually, there is a function to add descriptive labels in Excel 2013:
After you have created your XY Scatter Graph, selected X- and Y-values and clicked "Add Data Labels" (4:15 in this video), do the following:
1. Click on one point so that they are all highlighted
2. Right click on one of them (while all are highlighted), and click "Format Data Labels"
3. Under "Label Options" appearing on the right side (default), deselect "X Value" and "Y Value"
4. Select "Value From Cells"
5. Click on the button "Select Range"
6. Now, select the row containing data for your labels (for example the "items" column)
7. Voilà, you have custom labels with no coding needed.
***** +eivihnd Thanks to both of you. Helped a lot!
+Doug H I have Excel for Mac 2011 so I still had to use the macro. Thanks for saving me time!
+eivihnd THANK YOU!
+eivihnd real MVP
+eivihnd oh wow so nice! Thank you sir.
YOU ROCK. I have been using excel since 1996 and have been frustrated by my inability to add labels. Thank you!
You just saved my entire day. Been spending all day trying to add data labels, but with your video it only took 5 min's. Thank you very much!!
You're welcome...glad it helped!
This was the BEST tutorial I found to figure out how to add data labels to a scatter plot chart. Doug -- Thank you so much for posting this!
Wow.... thanks for the kind words!
I searched for an hour and this is the best explanation I found. Good work! (although you could skip the first 2:20 of the video). Thank you
Thank you so much, Doug!
I didn't know it was not possible to label data points in a scatter chart in Excel. I was desperate...
You’re welcome!
Thank you so much!! I've been trying to figure out how to do this and no-one in my office knew the answer. But you did - and made my life so much easier! Thanks very much!
You're welcome...thanks for the comment!
I did same in my project with help of this video and I got award.
thank you sir
Good job man!!
Sir, please share you mail id because I have prepared one Excel VBA programming for automatically send mail from Excel when due date reached.but email continues trigger after reach due date. I need to stop the mail in the VBA programming. Please support
Thanks Rajesh Dakshanamoorthy, glad it helped!
Your video was awesome! The right pace, the right explanation (except maybe for how to create the macro itself), and the end result! Thanks so much
Glad you liked it!
Fixed the problem I had by 'adding data manually' just like how you said.. Thanks man!
Thank you Doug. Appreciate your time and effort to create this tutorial. I'm running Excel 2010, so the 7-step process posted by eivihnd is not available to me. But since I am running Excel 2010 this tutorial is a great help.
Thanks a lot Doug. I have successfully attached labels on my excel graphs thanks to your guidance. Much appreciation!!!
Glad this helped. Thanks for the comment!
Thanks for the great tutorial. Clear and concise instructions. Saved me hours of work.
This was very helpful, thank you. When running the macro, you have to have the chart selected, or else it won't work.
Wonderful! This helped me create a great scatter plot of the revenue and gross margin for our company's product lines. Thank you!
Thanks Michael Newman, glad it helped!
When you add the macro in VBA, you have to do it as "insert / module", otherwise it doesn't work. At least that fixed the problem for me. Thanks for the video!
You're welcome!
Thanks so much for the video! This is exactly what I have been trying to do for days! Now, if I could only control the labels...meaning show and hiding based on what I am sorting...
Try using the NA() function for the second table that sources the chart. See this video for some insight. ruclips.net/video/2pF7sKR8wRQ/видео.html
Hi Doug
Many thanks for this video. I managed to add labels for the first time with them all aligned properly. I did find a couple of issues with filtering data and the code was then mis-aligned. But as I said managed it for the first time with my usual Excel jiggery pokery, thanks again.
You're welcome, glad it worked for you!
Thanks a lot Doug H! It saved my dissertation thesis graphs! FYI, the macro code I took from the link you give here didn't work. I used this one instead:
Sub AttachLabelsToPoints()
'Dimension variables.
Dim Counter As Integer, ChartName As String, xVals As String
' Disable screen updating while the subroutine is run.
Application.ScreenUpdating = False
'Store the formula for the first series in "xVals".
xVals = ActiveChart.SeriesCollection(1).Formula
'Extract the range for the data from xVals.
xVals = Mid(xVals, InStr(InStr(xVals, ","), xVals, _
Mid(Left(xVals, InStr(xVals, "!") - 1), 9)))
xVals = Left(xVals, InStr(InStr(xVals, "!"), xVals, ",") - 1)
Do While Left(xVals, 1) = ","
xVals = Mid(xVals, 2)
Loop
'Attach a label to each data point in the chart.
For Counter = 1 To Range(xVals).Cells.Count
ActiveChart.SeriesCollection(1).Points(Counter).HasDataLabel = _
True
ActiveChart.SeriesCollection(1).Points(Counter).DataLabel.Text = _
Range(xVals).Cells(Counter, 1).Offset(0, -1).Value
Next Counter
End Sub
Hi, thank you it worked for me this code aswell. Thank you too Doug H
It's work Very Well, thanks for you code!!!
Thank you so much I was so confused on how to create different series for scatter plots!
You can right click a point on the scatter plot and click on "add data labels" then manually change the label of each point on the graph.
Hi Skid, thanks for the comment!
I'm SOOO excited! Thank you SO MUCH for both the pointers!
Hi Deb Phillips, glad you liked it, thanks for commenting!
Really helpful, thank you. Worked first time in Excel 2010.
Thanks mattnicks, glad it helped!
Thank you very much. Very helpful!
May be relevant to highlight that your excel file should allow macros. Sometimes it is not the case by default. Hence when saving the macro you receive a warning and you should click on "no" and choose a macro-enabled excel format. I wasted a hour because of that
Hi Roberto M, thanks for the comment!
first answer that makes sense - you are my hero! and the macro works! thank you so much!
You're welcome; thanks for the comment!
Thank you Doug! that is helpful. This option should be available through "Format data labels" by clocking on any data point.
Hi Elton Mammadov, glad you liked it, thanks for commenting!
What a life saver. Thank you
Hi Joseph George, thanks for the kind words!
Thank you very much my friend Mr. Doug H. I appreciate your video.
Hi Gangaram Choudhary...you're welcome, glad you liked!
It's kind of crazy that Excel doesn't do this for you. One would think it's just common sense to have that
Oh great to know, thanks Doug!
It does! - see eivihnd above. Also works in Excel 2016. For some reason excel keeps quiet about it.
Hi Juan Ramirez, thanks for the comment!
Awesome. Thank you! Your explanation was v. clear and worked first time.
Thank You!!!! Manually added the data and it worked.
Hi Doug H,
I think it would be best if you posted the solution from eivihnd into the summary. This would have saved me a lot of time If I knew ahead of time when reading the summary, "IF YOU HAVE EXCEL 2013 just read the steps below"
Actually, there is a function to add descriptive labels in Excel 2013:
After you have created your XY Scatter Graph, selected X- and Y-values and clicked "Add Data Labels" (4:15 in this video), do the following:
1. Click on one point so that they are all highlighted
2. Right click on one of them (while all are highlighted), and click "Format Data Labels"
3. Under "Label Options" appearing on the right side (default), deselect "X Value" and "Y Value"
4. Select "Value From Cells"
5. Click on the button "Select Range"
6. Now, select the row containing data for your labels (for example the "items" column)
7. Voilà, you have custom labels with no coding needed.
Thanks,
-Jeremy
And then sum? Do you know how to automatically adjust the min and max for the x and y axis based off the min and max of the data selected? This way u only see the grid where my points are and not from 0?
Hi Jeremy Lowrey, thanks for the comment!
you're a hero, Doug! Fantastic. Thanks so much.
Hi Richard Vaughan, you're welcome!
Hi Doug,
Great video and it helped me a lot. The problem I am facing is that there are a lot of data points on the scatter plot which make data labels overlap and it gets difficult to identify. Is there a way to remove the data labels and only show them when we hover over the data point?
Thanks!
Just click and drag any overlapping data points to move them apart. excel puts in a little data pointer for you.
Thanks so much to both Doug and eivihnd!
Thanks, Doug!!
That's an excellent tutorial! Many thanks
You did not walk through the macro section...
Developer -> Visual Basic -> Insert -> Module -> Paste code and Save. Also, you will get an error unless both X and Y values are filled in.
thank you!! this was really helpful.
Hi Matthew Morton, thanks for the comment!
thanks so much. Extremely useful. Had been trying for several hrs
Hi Indra Bishop, glad you liked it, thanks for commenting!
Excellent job ! Thank you so much for making this video.
Hi Gary Kassabian, you're welcome!
Thanks, Doug!
My scatter has hundreds of points with dense concentrations in areas; the labels appear per your instructional, but are cluttered and cannot be read/presented. Any idea on how to do this, so that when you hover your mouse, the label appears ala a standard chart with auto labels?
You've saved me hours of work
Hi Doug - please could you post the code here, as the link no longer works. Thanks!
Thanks to Doug H and Thomas Paine!
You're Welcome!
Really nice. thanks dude. I learnt a lot of stuff with this vid
Thank you very much Sir!
You're Welcome!
excellent demonstration. Thank you.
Hi Ali Khan, thanks for the comment!
Thanks, was driving me nuts!
Glad you liked!
Thanks so much! I couldn't do this over my class, but now "IT WORKS". Btw, Do I need to select the data that I want to create a Scatter-plot?
Glad it worked for you. Yes, you'll need to select the data to fill out the chart, that can be done before or after you Insert>Chart
This was super helpful. thank you!
You're Welcome! Glad you found it helpful!
Thanks so much for this! It worked perfectly!
Hi Helena Hall-Manning...you're welcome, glad you liked!
Hey I just want to say that there is a much easier way:
1. Block all your data
2. Create a scatter plot graph
3. Add chart element and add data labels
4. Right click on the label, click on "Format Data Labels"
5. Tick "Value From Cells" and select the range of names that you want
TIPS:
I once cannot find "Value From Cells" check mark, then I found out that we must confirm that the Excel you're running is not on "Compatibility Mode".
How do you know that your Excel is running on compatibility mode or not? Look at your Excel top window. If there is "[Compatibility Mode]", then you will never find the "Value From Cells" check mark.
The simplest way to fix this is just create a new Excel book, copy all your data needed from the past Excel book and paste it to the Excel book that is not running on compatibility mode, then do step 1-5 again.
Hi Putu Gede Bhismananda, thanks for adding to the thread!
Thanks this really helped. But my labels have very long names. So if I just want each label to have a separate symbol/colour in the graph and then have the labels to appear as legends at the side, how do I do that? I have 14 such labels.
maybe something like this ruclips.net/video/sNQxUTs6lJA/видео.html can give an idea. It'll need to be combined with a change in the series name to reflect the label name.
This worked great except for one thing. When I ran the macro, it also plotted a point (0,0) for the Item column heading. How do I fix that?
Thank you very much Doug. Great tutorial. Do you happen to know how I can loop through each series in my chart?
Simpler code:
Sub Macro1()
ActiveSheet.ChartObjects("Chart 1").Activate
'1 chart number
For i = 1 To 3
'3 is the total number of points
ActiveChart.FullSeriesCollection(1).Select
ActiveChart.FullSeriesCollection(1).DataLabels.Select
ActiveChart.FullSeriesCollection(1).Points(i).DataLabel.Select
Selection.Formula = Cells(7 + i - 1, 3).Value
Next i
Range("A1").Select
End Sub
Hi SES DESIGN, thanks for adding to the thread!
Thank you! that was really good explaining! :D
Hi PernilleDahl, you're welcome!
Thank you that worked wonders.
Hi Jacob Colegrove, glad you liked it, thanks for commenting!
Great video. Really helped me out.
Glad it helped you!
Loved the video...very informative.
Hi Akshay Kamath, thanks for the comment!
This vid helps a lot...
Thank's so much :)
Super helpful, thank you!
Glad you liked!
Thanks a lot. This is really good!
Hi Dadawa, thanks for the comment!
Fantastic. Thanks very much
Awesome, thanks Doug!
+Wayne Barthule Glad you liked!
Hi Doug - great presentation and thank you very much - this was very helpful. Recently we needed to edit/change the label value. So we changed the label name in the Excel column, but the graph did not automatically update to reflect the new value. How do we do this so it's automatic and we don't have to do the whole thing over?
if you've got Excel 2013, you can actually put labels without any VBA. See video at ruclips.net/video/NnoFXSFBtIg/видео.html
If you don't you'll have to do it over again :-(
thank you so much! this is really helpful :)
Thanks tinypeaces, glad it helped!
Thanks, this just saved my project!
***** hi Doug. could you please share the Macro that you used for data label. i can not find that!
***** highly appreciated!
***** hi Doug! i found sth else in this case. it is called "XY chart Label". i downloaded it for free also: [ www.appspro.com/Utilities/ChartLabeler.htm] it is very useful for those people who wanna labeling a lot of different data.
that was excellent thanks dude
thanks, very helpful video!
Thanks like piano, glad it helped!
very helpful, thanks
Do you know if the code works with negative values? I tried doing it, but it does not seem to work
Thanks a lot. Nice tutorial :)
You're welcome!
Thanks, very helpful
You're welcome!
Perfect! Thank you!
Very useful. Thanks!
Hi Alex , thanks for the comment!
Hi, thanks for the video! How does one edit the macro so that it displays name, x-axis figure, and y-axis figure as well?
Excel 2013 - I am trying to show results of two measurements (y is measurement one, x is measurement 2), each unit of measure is minutes spent playing video games. The x data is what my observer recorded (number of minutes each child spent playing video games, 20 children total). Y data is what observer 2 recorded (in minutes for each child spent playing video games). So - my coders viewed video tapes of areas in which children spent time playing video games. [interrater reliability] - and I want to show this in a scatterplot in which the first set of data (y) and the second set of data (x) are on the same scatter chart - but I get to the part in your video in which you manually add the chart (7:22) and my spreadsheet does not appear the same - my chart styles look completely different. Do I need to customize or add something to my access tools? Thanks - sorry if this totally confuses you - I'm totally stuck on this!
Soo you can have the series name display the data label value, but I had to add each point individually. In 2013, I have to add each data point individually in the select data box. Once the point is in, I add the data label, in the data label I select the series name, and x value option and in my case, I enter a new line. I use the scatter chart to make milestone across a range of dates. In 2016 it did it just fine. It pulls the series name as the data label, the x values is a date in my data and the y value is the vertical position. My extra layer is it all has to show in office 365 so our employees can access the graph on their phones.
Hi Maggie Badaraco, thanks for the comment!
How would a draw a line down the middle the perfectly split the chart? Thank you Doug H!
very helpful !
thank you very much! very helpful :D
Thanks Ratnabhsl, glad it helped!
Thanks a lot this helped me
Glad it helped; thanks for the comment!
Very useful!
Thanks! It helped a lot! :)
Hi Dalma dr. Geréné dr. Radványi...you're welcome, glad you liked!
Thank you so much for sharing, Doug. But is it only me that I googled more than 3 pieces of code and none of them work or it's the same with other ppl?
The description field in this video has a link to the msft site so hope that helps.
Dear Doug: your video helped me a lot. Thanks. My scatter plot has different legends(e.g. It has 2 series), then the code cannot add labels, and give "Object variable or with block variable not set" error. Could you please help me on this? Thanks
Nice macro, thanks.
Thanks!
Thank you thank you thank you!
You're Welcome!
Thanks for the script!
Wow thanks so much for this
Hi Phillips Choe, you're welcome!
For Excel 2013+ there is another possibility without the need for a macro.
See here: exde601e.blogspot.de/2014/11/adding-labels-to-excel-scatter-charts.html
Hi Markus Hanisch, thanks for the comment!
Hi,
Works great. I get the following error though. Using Excel 2010
Object variable or Block Variable not set
Can you assist please.
Thanks Doug. This works fine for me, but I'm having issues when I include more than one data series. In this instance, only the first data series is labelled when I run the macro.
Do you have any advice?
James Haythornthwaite I managed to fix this - you need to change the series number in the brackets after any reference to "SeriesCollection" in the macro to then apply the macro to that specific series.
Cheers
James Haythornthwaite how about if I have 40 different series? How did it work for you with more than one data series? Thank you!
Is it possible to seperate the labels even more? As Items 15, 17 and 19 are pretty close together?
Yes click on the label. The 1st click select all, a 2nd click should just be that label. Then you can move the text box around
Hey Doug, I currently have an excel sheet with 3 series!
All the data of the 3 series are in a sheet (DataSheet), and the chart is in separate worksheet loading the data from the datasheet.
First of all would I need 3 different sheets for each series so i can apply the labels and does the chart need to be on the same sheet when loading the data? Also when I apply the macro, do I apply to the entire excel file, or on the sheets or on the tabs for this scenario!
Thanks in advance!
+Doug H Well the client hasnt upgraded to 2013 which doesnt allow me to work on it!
Why I say I have to put each series in a seperate sheet, because the code assumes that the first column contains the label and the other 2 columns contain values to load from!
What if I told you, I just I found a way that is not shown on the Internet and is far easier than yours but requires slight manual labor and no Macro!!!
H Doug - I have tried this macro, however it provides for an error.
"xVals = Mid(xVals, InStr(InStr(xVals, ","), xVals, Mid(Left(xVals, InStr(xVals, ",") - 1), 9)))"
I guess it pretty much has to do with the range that is being sellected. Please advise?
If you have Excel 2013 or later, there is a function to add descriptive labels you can actually put labels without any VBA. See video at ruclips.net/video/NnoFXSFBtIg/видео.html
thanks man
You're Welcome!
Nice job!
Thanks!
why was first graph not correct and then you did custom?