Dynamic chart range not displaying all Horizontal Axis Labels

Peter Davison

Active Member
Joined
Jun 4, 2020
Messages
451
Office Version
  1. 365
Platform
  1. Windows
I have created a chart from data in Cells DR5 to DY7 - Although the DY7 could be more columns which is why I am trying to make it dynamic (see below)
I am using this Named Range called - Numberofstores
=IFERROR(OFFSET(Assortment!$DR$5:$EZ$7,0,0,3,COUNT(Assortment!$DR$5:$EZ$5)*1),"")
but as you can see it is still only displaying the one line (Row 5).
I don't think I have the named range formula correct.
Any help would be appreciated.

1707741213788.png
 
This automatic macro is on a different sheet, that shouldn't be a problem should it?
There are no other macros on this workbook.

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Cells.EntireColumn.AutoFit
End Sub
 
Upvote 0

Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.
I'm just going into a meeting now so I'll have a look first thing in the morning to see if I can just use the bit for the chart on a different file?
 
Upvote 0
Autofitting column widths shouldn't make any difference.
 
Upvote 0
It looks like I have cracked it.
I re-created the data into a new position and it worked, no idea why it wouldn't work before.
So all good.
And...
Again thanks for all your help.

Regards
 
Upvote 0
You've gotta love a solution that works but makes no sense. :) Glad it's fixed.
 
Upvote 0

Forum statistics

Threads
1,223,893
Messages
6,175,240
Members
452,621
Latest member
Laura_PinksBTHFT

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