Dynamic Ranges for Charts
Hey all,
i've looked everywhere for a solution for this but haven't found one yet.
I'm looking for a way to use a dynamic range for the data which should be used for a chart. I still can't get the .values property assigned in such a way that it works. I already have the needed column number (col As Long, colRef as String) And the rownumbers are fixed (16 & 18).
How should i assign the .Values property so it will use the combined data of column col (long) or colref (string)?
And more in general how to use the .Values property of a chart for any datarange with dynamic row (long) , col (long) ranges (multiple cells ; in a row/column or different combined ranges)
* part of code
Code:
With ActiveChart.SeriesCollection.NewSeries
.Name = Sheets("Data").Range("A16")
.Values = Sheets("Data").Range(colRef, "16", colRef, "18").Value
...
End With
Many thanks in advance,