Gantt chart and clear series

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
AB Prod
Newbie
Newbie
Posts: 10
Joined: Wed Apr 10, 2013 12:00 am
Location: Paris France

Gantt chart and clear series

Post by AB Prod » Fri May 24, 2013 12:22 pm

Hi,

i use a TChart with one and unique TGanttSeries that i fill and clear by code. On the application launch the Chart is empty, it is filled up by the result of a search (done by an user).
Then my user can do another search and there the problem occurs, when my code clears of the TGanttSeries with the following statement "MySerie.Clear;"
my application crashes and display the following Exception:

EAccessViolation
Violation d'accès à l'adresse 00403859 dans le module 'VOD_LDS.exe'. Ecriture de l'adresse 00000000.

I decide to test the same action by using the delete method so i did a loop:

for i := MySerie.Count - 1 downto 0 do
MySerie.Delete(i);

And then in this case my app crashed on the deletion of the last element of the serie with the following exception:

EInvalidPointer
Opération de pointeur incorrecte.

I know there is an element "0" because if i stop the loop on 1 for example, on display i can still see the first item of the previous search action mixed with the new ones.

Please help? What did i do wrong?

Tia & BR

Laurent

AB Prod
Newbie
Newbie
Posts: 10
Joined: Wed Apr 10, 2013 12:00 am
Location: Paris France

Re: Gantt chart and clear series

Post by AB Prod » Fri May 24, 2013 1:39 pm

I played also with the Active property ... no success.
I tried also freeing the Serie and recreating it ... same issue.

Laurent

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

Re: Gantt chart and clear series

Post by Narcís » Fri May 24, 2013 2:38 pm

Hi Laurent,

Could you please attach a simple example project we can run "as-is" to reproduce the problem here?

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

Post Reply