Page 1 of 1

Real Time Chart

Posted: Mon Sep 05, 2005 3:57 am
by 9339722
Hi,

I was wondering if a TChart component can be used for real time chart display which is updating every second. I am making an app which monitors incoming and outgoing data every second and shows a real time chart of bytes sent and received.

If possible which Series should I use..?

These are the preferred functions.
Any given time last 60 seconds of data is to be visible.
It should scroll as time goes by showing last 60 seconds only.
Time is on X Axis and Bytes sent and received are on Y axis.

What properties should I set for the chart and/or seried to make above happening..?

Any help would be appreciated.

Cheers :)

Posted: Mon Sep 05, 2005 7:22 am
by narcis
Hi,

Yes, TeeChart can do real-time charts. Here you'll find an excelent article about using TeeChart for real-time charting. If after reading it any of your questions is still unanswered please feel free to post them here.

Posted: Mon Sep 05, 2005 10:48 pm
by 9339722
NarcĂ­s,

Thanks for the quick reply.

This is what I did.

Started a new application. Dropped a chart component and I ran the program and saw a form with chart on it.

Then I added a FastLineSeries and run the program again and I get the error even before I can see the form. Follwoing is the error.

Exception EReadError in module Project1.exe at 0001A752.
Error reading Series1.Marks.Callout.Brush.Color: Property Callout does not exists.

I press OK and the app dies. I haven't added any code from the page link you posted. I am using TeeChart 7 with Report Builder 7.04

Any idea..?

Posted: Tue Sep 06, 2005 12:05 am
by 9339722
OK fixed the above problem by reinstalling the TeeChart. Damn I should have thought that before.

So now I can see the chart being generated in real time but the scroll bar wont work and the chart goes out of chart boundry. I think I am missing something really small to make the whole thing work.

I would like to it to automatically scroll when it reaches the right edge and then continue along scrolling with it.

I appreciate the time you are devoting to help other.

Cheers,

Nirav

Posted: Tue Sep 06, 2005 7:29 am
by narcis
Hi Nirav,

I've modified your project so that it works and posted it at [url]news://www.steema.net/steema.public.attachments[/url] newsgroup.

The problem it not scrolling was that even your bottom axis ranged from 0 to 10000, your XValues easily reached the 10000 value and thus were displayed out of the axis range. However it didn't scrolled because it took some time to generate 10000 points (see the form1 caption which shows you the number of points generated).

Posted: Thu Sep 08, 2005 12:06 am
by 9339722
Thanks a lot Narcis. That pretty much solved all the problems creating a proto type I was doing.

Again your help is much appreciated :)