Hi Tony,
Thinking a little bit further about this issue, the stacking algorithm will work correctly *only* if all series have the same number of points and point x values coincide. If this is not the case, you'll have to use AddNullXY method to add "missing points". I'd use the following approach:
1) Make a list of all available (pool) of x values.
2) For individual series, cycle through (1) and use AddXY if point (x,y) exists and AddNullXY if specific point (x,y) does not exist for this series.
An easier alternative is setting MultiBar to mbNone, for example:
Code: Select all
Private Sub Form_Load()
Dim i As Long
TChart1.RemoveAllSeries
For i = 0 To 5
TChart1.AddSeries scBar
TChart1.Series(i).asBar.MultiBar = mbNone
TChart1.Series(i).asBar.BarWidthPercent = 20
TChart1.Series(i).AddXY i, i * 2, "", TChart1.Series(i).Color
Next i
End Sub
So we have closed the issue in the bug list.