General Series related questions


Q: How can I change the Series order at run-time?


The order series are drawn is the same as Series order inside the Chart1.Series array property. You can move Series to the front or to the back using the Chart1.ExchangeSeries method. Mouse Clicks are checked in reverse order (Series in the back are drawn first).


Q: Does your Pie Chart provide for hypertext jumps from each slice or label?


The Pie Chart has OnClick events that allow you to add the hyperlink jump with your code. All TeeChart Series have OnClick events that pass Index values that may be used for Drilldown or other onward processing.


Q: I want to change the colour of a data point according to its value. How can I do it?


You can use the PointColor property evaluating each Point's value and applying your own colours:

Private Sub Form_Load()
Dim t As Integer
TChart1.AddSeries scPoint
For i = 1 To 14
    TChart1.Series(0).AddXY i, Rnd(i) * 100, "", clTeeColor
Next i
TChart1.Series(0).ColorEachPoint = True
For t = 0 To TChart1.Series(0).Count - 1
    If TChart1.Series(0).YValues.Value(t) < 50 Then 'put your threshold here
        TChart1.Series(0).PointColor(t) = vbRed
    Else
        TChart1.Series(0).PointColor(t) = vbBlue
    End If
Next t
End Sub