Overlaying a Saved Native Tee file on an existing plot

TeeChart for ActiveX, COM and ASP
Post Reply
AR
Newbie
Newbie
Posts: 9
Joined: Wed Dec 01, 2004 5:00 am

Overlaying a Saved Native Tee file on an existing plot

Post by AR » Tue May 24, 2005 8:28 am

I am trying to find a way to load a saved file (native teechart format) and to overlay this data on an existing plot. Assuming both datasets have the same axes.

Using the Import interface and the LoadfromFile function, the existing plot is erased. One way I have though to do this is to custom create a datafile that has all the data, both the current and the saved data, however this seems clunky.

The native import facility doesnt seem to have a load to a defined series functionality.

Is there any way to achieve what I want to do without having to create a file with both datasets merged ?

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 May 24, 2005 9:25 am

Hi AR,

You should separate chart characteristics and chart data.

You could export/import chart characteristics using .tee file. Regarding the data you could export it to whatever format you wish using the chart export formats and then import it to the existing chart.
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

AR
Newbie
Newbie
Posts: 9
Joined: Wed Dec 01, 2004 5:00 am

Post by AR » Tue May 24, 2005 12:43 pm

I dont want to be generating more than 1 data file for a save. Currently all I can see to do would be to copy the current chart data to memory, load the chart data from file and then readd the data from memory

When I tried to export to a XML data format and read the data back, I ran into the problem that the EnterSeries and exitSeries events did not fire for data read back in via the XMLdatasource component.

I only could seem to get the EnterSeries and ExitSeries events to work when I imported a tee file or I imported a tee file that had been converted to text using the supplied functions. Importing as a tee file erases the current graph.

I can solve the problem by storing the data as outlined in the 1st paragraph but this seems clunky

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 May 24, 2005 2:38 pm

Hi AR,
When I tried to export to a XML data format and read the data back, I ran into the problem that the EnterSeries and exitSeries events did not fire for data read back in via the XMLdatasource component.

I only could seem to get the EnterSeries and ExitSeries events to work when I imported a tee file or I imported a tee file that had been converted to text using the supplied functions. Importing as a tee file erases the current graph.
Could you please clarify which events are you using as EnterSeries and ExitSeries are not TeeChart standard events. Also what are you trying to achieve with those events, we may suggest you a solution.
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

AR
Newbie
Newbie
Posts: 9
Joined: Wed Dec 01, 2004 5:00 am

Post by AR » Wed May 25, 2005 7:31 am

The events being used are

SINK_ENTRY_EX(IDC_TCHART1,DIID_ITChartEvents, 201, OnMouseEnterSeriesServicegraph)
SINK_ENTRY_EX(IDC_TCHART1,DIID_ITChartEvents,202, OnMouseLeaveSeriesServicegraph)

I am using these two events to allow the user to see via a text box the current series they are hovering over and the value at the mouse pointer.

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

Post by Narcís » Fri May 27, 2005 7:40 am

Hi AR,

Are you reassigning the events after importing your chart data/series? That may be the reason because of them not being fired.
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

AR
Newbie
Newbie
Posts: 9
Joined: Wed Dec 01, 2004 5:00 am

Post by AR » Tue May 31, 2005 12:51 pm

I am not reassigning them after Chart Import, will look into how to do that

Post Reply