I'm using the below code to try to define the min and max of the x range on a chart with two numbers that I have dynamically named in a cell (Chart_Date_Pmonth and Chart_Date_Tmonth). These numbers change over time. However, I cannot get the code to accept these named variables.
![]()
ActiveChart.Axes(xlValue).Select Set ActiveChart.Axes(xlValue).MinimumScale = Chart_Date_Pmonth Set ActiveChart.Axes(xlValue).MaximumScale = Chart_Date_Tmonth
Bookmarks