Hi,
If this has been answered elsewhere please feel to provide link to the thread. I have been searching for a while but haven't been able to find an appropriate answer.
Problem
I'm trying to create a line chart using "Scatter with Straight Lines" that will create a gap in the line if Y values don't exist for a given X value. The chart data series are arrays of values calculated in VBA and assigned to the chart. I have found the gaps will generate correctly if the data series were referencing a Range on a worksheet but I haven't had success if the data series is an Array.
Solution Attempts
To create the graphs, I have tried placing the following in the array where the gaps should occur.
""
#N/A
NA()
CVErr(xlErrNA)
vbNullString
I also tried changing to chart type "Line"
I'm trying to avoid printing the VBA values to a worksheet and then referencing the worksheet range. Because the workbook I'm creating is for making various charts from data the user provides. The charts will be created across multiple worksheets that the user defines and the number of charts, as well as, the order the charts are created in is not known ahead of time.
Any help is greatly appreciated! Even if "not possible" is the answer.
If this has been answered elsewhere please feel to provide link to the thread. I have been searching for a while but haven't been able to find an appropriate answer.
Problem
I'm trying to create a line chart using "Scatter with Straight Lines" that will create a gap in the line if Y values don't exist for a given X value. The chart data series are arrays of values calculated in VBA and assigned to the chart. I have found the gaps will generate correctly if the data series were referencing a Range on a worksheet but I haven't had success if the data series is an Array.
Solution Attempts
To create the graphs, I have tried placing the following in the array where the gaps should occur.
""
#N/A
NA()
CVErr(xlErrNA)
vbNullString
I also tried changing to chart type "Line"
I'm trying to avoid printing the VBA values to a worksheet and then referencing the worksheet range. Because the workbook I'm creating is for making various charts from data the user provides. The charts will be created across multiple worksheets that the user defines and the number of charts, as well as, the order the charts are created in is not known ahead of time.
Any help is greatly appreciated! Even if "not possible" is the answer.