Changing series data, cursor tool data isn't change

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
Herman
Newbie
Newbie
Posts: 56
Joined: Tue Dec 07, 2004 5:00 am

Changing series data, cursor tool data isn't change

Post by Herman » Tue Dec 20, 2005 1:42 am

I have a fast line series and a cursor tool.
I have write the code to get the cursor data for OnSnapChange and OnChange event. My problem is: I change the cursor data, but both OnSnapChange and OnChange event doesn't get executed.
I have called CursorTool1->repaint(), chart1->update but it's all the same.
So series has been changed but the displayed cursor data isn't. Is there a simple way to solve this?

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Tue Dec 20, 2005 11:28 am

Hi Herman,

It works fine here using v7.06. Which TeeChart version are you using?
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Herman
Newbie
Newbie
Posts: 56
Joined: Tue Dec 07, 2004 5:00 am

Post by Herman » Tue Dec 20, 2005 11:52 am

I'm using v7.05.
Well it works fine when i use button or move the cursor using the mouse.
Only when i change the series data, without doing anything to the cursor tool; OnSnapChange and OnChange event of charttool doesn't get executed

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Tue Dec 20, 2005 12:13 pm

Hi Herman,

Can you please test if v7.06 works at your end? If not, could you please send us an example we can run "as-is" to reproduce the problem here? You can post your files at [url]news://www.steema.net/steema.public.attachments[/url] newsgroup.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Wed Dec 21, 2005 4:04 pm

Hi Herman,

We don't understand the problem. It works as it should, if you load data and assign an X value to the cursor (3 for example), after loading new data the cursor remains at its position (position 3). Otherwise, what do you think it would do? Could you please be more specific on the problem?

Thanks in advance.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Herman
Newbie
Newbie
Posts: 56
Joined: Tue Dec 07, 2004 5:00 am

Post by Herman » Thu Dec 22, 2005 5:27 am

The cursor position is correct but the cursor value shown isn't. The value is the old value, before i called to change the series data.
I think the problem is because i write the code for updating cursor value in OnSnapChange event.

Pep
Site Admin
Site Admin
Posts: 3274
Joined: Fri Nov 14, 2003 5:00 am
Contact:

Post by Pep » Fri Dec 23, 2005 11:23 am

Hi Herman,

I'm sorry, I don't understand nor see where is the problem. Using the following code :

Code: Select all

procedure TForm1.BitBtn1Click(Sender: TObject);
begin
Series1.FillSampleValues();
Edit1.Text:=floattostr(charttool1.XValue);
Edit2.Text:=floattostr(charttool1.YValue);
end;

procedure TForm1.FormCreate(Sender: TObject);
begin
Series1.FillSampleValues();
Chart1.Draw();
Edit1.Text:=floattostr(charttool1.XValue);
Edit2.Text:=floattostr(charttool1.YValue);
end;
Both textBox are displaying the same values always, even if I click the button to add Random values to the Series.
Could you please post the code you're using so we can reproduce the problem here ? or post an example iinto the news://www.steema.net/steema.public.attachments newsgroup ?

Post Reply