Page 1 of 1

two charts on website - loading data from first to second

Posted: Wed Aug 27, 2008 7:48 am
by 9535493
Hello,

I have specific question;
I would like to have two charts on website,
1st is 3D chart.
problem is how to draw
the second one as 2D - slice of the first (for specific value on one axis)

I would like to do that on client side - because of speed - if it is possible.

thanks

Posted: Wed Aug 27, 2008 7:59 am
by narcis
Hello adenin,

Yes, you can do something like this:

Code: Select all

Private Sub Form_Load()
    TeeCommander1.Chart = TChart1
    TeeCommander2.Chart = TChart2
    
    TChart1.AddSeries scSurface
    TChart1.Series(0).FillSampleValues 10
    TChart1.Legend.Visible = False
    
    TChart2.AddSeries scLine
    TChart2.Series(0).asLine.Pointer.Visible = True
    
    For i = 0 To TChart1.Series(0).Count - 1
        'Draw 6th row
        If TChart1.Series(0).asSurface.ZValues.Value(i) = 5 Then
            TChart2.Series(0).AddXY TChart1.Series(0).XValues.Value(i), _
                                    TChart1.Series(0).YValues.Value(i), _
                                    "", clTeeColor
        End If
    Next
End Sub

Posted: Thu Aug 28, 2008 8:09 am
by 9535493
thanks,

it works exactly like I want