RealTime Chart
RealTime Chart
Hello,
I create a realtime chart with the TeeChart for .net. And I find the memory will be increased slowly when the real-time chart building. The memory will be increased 3M—5M in 24 hours. How could I solve this problem?
I create a realtime chart with the TeeChart for .net. And I find the memory will be increased slowly when the real-time chart building. The memory will be increased 3M—5M in 24 hours. How could I solve this problem?
Re: RealTime Chart
Hello Candy,
I recommend take a look in our Technical articles concretely in Real-time Charting. If it isn't sufficient please, send us your project, so we can reproduce your problem exactly here, and try to find a solution.
Thanks,
I recommend take a look in our Technical articles concretely in Real-time Charting. If it isn't sufficient please, send us your project, so we can reproduce your problem exactly here, and try to find a solution.
Thanks,
Best Regards,
Sandra Pazos / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: RealTime Chart
Hello,
The attachemt is my code which I used to built the Real-Time chart. Could you provide me some methods about how to improve the efficiency? Otherwise, I can't find the DrawAllPoints property of the tchart which mentioned in the Technical articles .Thanks!
Best Regards,
Candy
The attachemt is my code which I used to built the Real-Time chart. Could you provide me some methods about how to improve the efficiency? Otherwise, I can't find the DrawAllPoints property of the tchart which mentioned in the Technical articles .Thanks!
Best Regards,
Candy
Re: RealTime Chart
Hello,
I forgot to add the attachment in the last post. This is my code file.
I forgot to add the attachment in the last post. This is my code file.
- Attachments
-
- Class1.rar
- (3.24 KiB) Downloaded 640 times
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Re: RealTime Chart
Hi Candy,
Thanks in advance.
The easiest solution to reduce memory consumption is removing "unnecessary" points as shown in the DoScrollPoints method in the Real-time charting article. Otherwise data stays in memory. If no data is removed then memory consumption will increase. As far as I can see you are already doing that in UpdateLeftChart() method.Candy wrote:Could you provide me some methods about how to improve the efficiency?
This property only exists for FastLine series.Candy wrote: Otherwise, I can't find the DrawAllPoints property of the tchart which mentioned in the Technical articles .
Thanks, it was useful to see the nature of your application. Please bear in mind that using FastLine series would increase your application performance, not memory consumption as data is stored in the same way for Line and FastLine series. Also, FastLine series has no Pointer property, I see you are using it in your code. If you need that we run some tests with your code please attach a simple example project we can run "as-is" to reproduce the problems here.Candy wrote:I forgot to add the attachment in the last post. This is my code file.
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 |
Instructions - How to post in this forum |
Re: RealTime Chart
Hi Narcís ,
Thanks for your reply. The attachment is my test application. I following your method to modify my code,but the memory of my computer also increase when I run it.
Is there any other things should I do? And I notice that the cpu using is come up to 50%. What should I do?
Thanks for your reply. The attachment is my test application. I following your method to modify my code,but the memory of my computer also increase when I run it.
Is there any other things should I do? And I notice that the cpu using is come up to 50%. What should I do?
- Attachments
-
- WindowsFormsApplication1.rar
- (16.82 KiB) Downloaded 610 times
Re: RealTime Chart
Hello,
The attachment is my other test application. The memory increase from 20M to 40M in 6min when the application running. How could I to optimize my code?
The attachment is my other test application. The memory increase from 20M to 40M in 6min when the application running. How could I to optimize my code?
- Attachments
-
- TestTchartMemeory.rar
- (71.45 KiB) Downloaded 625 times
Re: RealTime Chart
Hello Candy,
Could you send again the last project, because the project you have attached doesn't work?
Thanks,
Could you send again the last project, because the project you have attached doesn't work?
Thanks,
Best Regards,
Sandra Pazos / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: RealTime Chart
Hi Sandra,
The attachment is the whole project.
The attachment is the whole project.
- Attachments
-
- TestTchartMemeory.rar
- (73.44 KiB) Downloaded 619 times
Re: RealTime Chart
Hello Candy,
I have tested your project for 15 hours and the memory oscillates from 35M to 40M, and doesn't increase exaggeratedly using last version of TeeChart.Net 2010.
Could you say us, which version of TeeChart are you using now?
Thanks,
I have tested your project for 15 hours and the memory oscillates from 35M to 40M, and doesn't increase exaggeratedly using last version of TeeChart.Net 2010.
Could you say us, which version of TeeChart are you using now?
Thanks,
Best Regards,
Sandra Pazos / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: RealTime Chart
Hi Sandra,
Thanks for your reply,I used the TeeChart.Net 2010 too.
Thanks for your reply,I used the TeeChart.Net 2010 too.
Re: RealTime Chart
Hello,
Beacause our applcation will run in a long time,so if the memory increased unending,it's not allowed. Is there any ways to prevent the memory increased?
Thanks!
Best Regards,
Candy
Beacause our applcation will run in a long time,so if the memory increased unending,it's not allowed. Is there any ways to prevent the memory increased?
Thanks!
Best Regards,
Candy
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Re: RealTime Chart
Hi Candy,
Thanks in advance.
Which is the exact TeeChart for .NET 2010 build you are using? Is it build 4.0.2011.02080, which is the latest release available? If not, can you please try using this build?I used the TeeChart.Net 2010 too.
The first and most important way to prevent the memory used by the application growing is removing data which is no longer used or visible. Otherwise TeeChart needs memory to store this data and you should expect memory consumption to increase. Having said that, if you are already removing unneeded data from your application and memory consumption is still growing in a uncontrolled manner it could be a memory leak in TeeChart. According to what Sandra wrote here that's not the case with your application, memory stays in the same memory usage range during the whole execution of the application. Is that what you experience at your end?Beacause our applcation will run in a long time,so if the memory increased unending,it's not allowed. Is there any ways to prevent the memory increased?
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 |
Instructions - How to post in this forum |
Re: RealTime Chart
Hello,
I want the memory usage doesn't increased when my application is running. Is there any method to implement it?
Thanks !
I want the memory usage doesn't increased when my application is running. Is there any method to implement it?
Thanks !
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Re: RealTime Chart
Hi Candy,
For us to be able to help you further on this issue could you please answer the question I made you in my previous reply?
Thanks in advance.
For us to be able to help you further on this issue could you please answer the question I made you in my previous reply?
If you get the same behavior as Sandra and I described here this is normal considering you are already removing points from your chart, which is the way to avoid memory usage increasing. Please notice that the .NET Framework doesn't free objects immediately, it's garbage collector who does that task. Therefore you may see memory consumption oscillations in your application. At this thread you'll find a more in deep discussion on garbage collector and TeeChart.I want the memory usage doesn't increased when my application is running. Is there any method to implement it?
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 |
Instructions - How to post in this forum |