Is there a condition that prevents XValues->Order from working? My values are always sorted lowest.. highest, even though I've set Order to loNone.
-Dean
Order doesn't work?
Hi, Dean.
If you set the Order property to loNone *before* you start adding points then it should work fine. Example:
If you set the Order property to loNone *before* you start adding points then it should work fine. Example:
Code: Select all
// draw an ellipse (parametric plot)
Series1.Clear;
Series1.XValues.Order := loNone;
for t :=0 to 20 do
Series1.AddXY(2*Cos(Pi*i/10),3*Sin(Pi*i/10));
Marjan Slatinek,
http://www.steema.com
http://www.steema.com
Hi Dean,
I've just test it here with the TeeChart Pro v5.03 and BCB5 and the following works fine :
I've attached the example and image I get in the public.steema.attachments newsgroup. Could you plese check is it works fine for you ?
I've just test it here with the TeeChart Pro v5.03 and BCB5 and the following works fine :
Code: Select all
void __fastcall TForm1::FormCreate(TObject *Sender)
{
Series1->XValues->Order = loNone;
Series1->AddXY(-3,10,"",clTeecolor);
Series1->AddXY(3,5,"",clTeecolor);
Series1->AddXY(-2,1,"",clTeecolor);
Series1->AddXY(2,13,"",clTeecolor);
}
Pep Jorge
http://support.steema.com
http://support.steema.com
The positive/negative thing wasn't an issue -- I spoke prematurely.
I guess this will just remain a mystery. I have :
* Set the XValues->Order property immediately after creating the series (a TLineSeries allocated and assigned to a TCustomSeries pointer at runtime, in the form constructor) and, for good measure, immediately after clearing the series before plotting new data.
* I've checked the data as I add it to the series.
* I've checked the contents of the XValue array right after my AddXY loop and in the OnGetAxisLabel handler.
* The XValues->FOrder property is 0 at every point in the code I check.
* The OnGetAxisLabel handler properly rescales the labels without changing the sign, and I did try taking it out altogether.
Everything looks just fine, except that the data insists on being plotted in ascending order, which is <B>exactly the opposite</B> of the order the data is inserted.
I have another plot class in which setting loNone seems to work, so I know TeeChart isn't just broken. I've compared this plot class to the other one and the chart code itself isn't much different. Hence the original question, whether there's some other setting in TeeChart that would make it change the data order, even if Order == loNone?
Thanks for looking into this.
-Dean
I guess this will just remain a mystery. I have :
* Set the XValues->Order property immediately after creating the series (a TLineSeries allocated and assigned to a TCustomSeries pointer at runtime, in the form constructor) and, for good measure, immediately after clearing the series before plotting new data.
* I've checked the data as I add it to the series.
* I've checked the contents of the XValue array right after my AddXY loop and in the OnGetAxisLabel handler.
* The XValues->FOrder property is 0 at every point in the code I check.
* The OnGetAxisLabel handler properly rescales the labels without changing the sign, and I did try taking it out altogether.
Everything looks just fine, except that the data insists on being plotted in ascending order, which is <B>exactly the opposite</B> of the order the data is inserted.
I have another plot class in which setting loNone seems to work, so I know TeeChart isn't just broken. I've compared this plot class to the other one and the chart code itself isn't much different. Hence the original question, whether there's some other setting in TeeChart that would make it change the data order, even if Order == loNone?
Thanks for looking into this.
-Dean