Replace chart labels with different range to source data

ollyhughes1982

Well-known Member
Joined
Nov 27, 2018
Messages
798
Office Version
  1. 365
Platform
  1. MacOS
Hi. I have this ‘lollipop’ chart in my workbook, which is fed by the range C3:D29. However, I would like to the replace the data labels in the chart for those in the range H3:H29. is this possible? I obviously don’t want to just change the source data range, as it won’t work for the three countries at the bottom.

Screenshot 2025-01-12 at 20.15.58.jpg

Screenshot 2025-01-12 at 20.27.23.jpg


The reason I want to do this is that for the countries where parkrun no longer operates (Zimbabwe, Iceland and Russia), I want to show both the start and end date, rather than just the start date, as with all of the other countries.

I’ve tried the option to select label range, but it just doesn’t seem to work.

The file can be found here: https://1drv.ms/x/c/f08b781118912fd2/EYHODi_Rs5dFgU0wak2UF14BLU6rBoAtG6PSp9lETKCfLw?e=VyDC9o

Thanks in advance!
 

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.
Is this what you wanted?
1736741476738.png


I deleted the existing labels and then added them again, and then replaced the default (which is Y value) with the range H3:H29. Note that the formula you were using to create the date TEXT was wrong - confusingly you need to use only three y's for a four digit year: =TEXT(A1,"mm/dd/yyy"), not =TEXT(A1,"mm/dd/yyyy").

Link to updated file
 
Upvote 0
Is this what you wanted?
View attachment 121197

I deleted the existing labels and then added them again, and then replaced the default (which is Y value) with the range H3:H29. Note that the formula you were using to create the date TEXT was wrong - confusingly you need to use only three y's for a four digit year: =TEXT(A1,"mm/dd/yyy"), not =TEXT(A1,"mm/dd/yyyy").

Link to updated file
Thanks, that’s almost it. I want the sates like that, but to also still have the country names as well
 
Upvote 0
I'd add those into the date cells:

=IFERROR(IF(C3="","",B3&CHAR(10)&IF(G3<>"",TEXT(C3,"mm/dd/yyyy")&" - "&TEXT(G3,"mm/dd/yyyy"),TEXT(C3,"mm/dd/yyyy"))),"")
 
Upvote 0
Solution

Forum statistics

Threads
1,225,730
Messages
6,186,700
Members
453,369
Latest member
positivemind

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top