Hello.
Can you please confirm that the following mechanism I'm using is fully supported, and it something that will always be supported.
I'm populating a line series by adding X(time), Y values. These are being added at a frequency say of 20 seconds. I then execute the following code to retrieve the DataSource of the series as a DataSet:
System.Data.DataSet penData = penSeries.DataSource as System.Data.DataSet;
This results in a DataSet retrieved from the series of all the sample pairs it currently contains. Repeating the above command returns the same dataset, even though new samples have been added. In order for me to retrieve the data including the new samples added since the last time the above command was executed, I have to also do the following:
penSeries.DataSource = null;
Only after setting the series DataSource to null, will I be able to retrieve all the samples from the series again.
Is this expected behaviour?
thanks,
Ben.
Retrieving series data as a dataset
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi Ben,
Could you please send us a simple example project we can run "as-is" to reproduce the issue here and let us know the TeeChart version you are using?
You make an example similar to Christopher Ireland's posted here.
You can either post your files at news://www.steema.net/steema.public.attachments newsgroup or at our upload page.
Thanks in advance.
Could you please send us a simple example project we can run "as-is" to reproduce the issue here and let us know the TeeChart version you are using?
You make an example similar to Christopher Ireland's posted here.
You can either post your files at news://www.steema.net/steema.public.attachments newsgroup or at our upload page.
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 |
Hi Narcís,
I have uploaded the test VS.NET project in a zip file called TeechartSeriestoDataGridView.zip.
If you run the application, you'll see one pen is created and samples (Time, value) are added every 5 seconds. When you click on the "Update Grid' button you'll see that the DataGridView instance will be updated with the entire set of samples contained in the series. If you look at the Click event handler for that button, you'll see how I've done this. Note, the 'nulling' out of the series.DataSource property is key to this functionality working (i.e. getting the full set of samples, the next time the button is clicked).
This functionality is good for our application and I'm hoping that it is officially supported for this version and later versions of the Steema TeeChart. (This version is 2.0.3203.23271/2).
thanks,
Ben.
I have uploaded the test VS.NET project in a zip file called TeechartSeriestoDataGridView.zip.
If you run the application, you'll see one pen is created and samples (Time, value) are added every 5 seconds. When you click on the "Update Grid' button you'll see that the DataGridView instance will be updated with the entire set of samples contained in the series. If you look at the Click event handler for that button, you'll see how I've done this. Note, the 'nulling' out of the series.DataSource property is key to this functionality working (i.e. getting the full set of samples, the next time the button is clicked).
This functionality is good for our application and I'm hoping that it is officially supported for this version and later versions of the Steema TeeChart. (This version is 2.0.3203.23271/2).
thanks,
Ben.
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi Ben,
Thanks for the example project.
Thanks for the example project.
Yes, this is by design.Only after setting the series DataSource to null, will I be able to retrieve all the samples from the series again.
Is this expected behaviour?
No. We can confirm that if the behviour is changed then an alternative mechanism will be made available to reproduce it.Can you please confirm that the following mechanism I'm using is fully supported, and it something that will always be supported.
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 |