Shape data editor causes AV

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
h.hasenack
Newbie
Newbie
Posts: 7
Joined: Mon May 13, 2013 12:00 am

Shape data editor causes AV

Post by h.hasenack » Thu Aug 29, 2013 7:05 am

Hi

I have been playing around with the YCHart MapSeries, and successfully managed to load ESRI shapefiles into a mapseries.

Howerver, when I open the TCHartedtor to review my shape coordinates a crash is caused. I added the following lines to Chart.pas, in PaintSeriesLegend(....) to fix the crash.

Regards - Hans

Code: Select all

....
  if Assigned(OldCanvas3D) then
  begin
    {$IFNDEF AUTOREFCOUNT}
{$ifdef HH_PATCH_TC_SHAPEDITOR}
     if Assigned(ASeries)
       and Assigned(ASeries.ParentChart) then
{$endif}
    ASeries.ParentChart.Canvas.Free;

    {$ENDIF}

{$ifdef HH_PATCH_TC_SHAPEDITOR}
     if Assigned(ASeries)
       and Assigned(ASeries.ParentChart) then
{$endif}
    TCustomChart(ASeries.ParentChart).InternalCanvas:=OldCanvas3D;
....


Yeray
Site Admin
Site Admin
Posts: 9612
Joined: Tue Dec 05, 2006 12:00 am
Location: Girona, Catalonia
Contact:

Re: Shape data editor causes AV

Post by Yeray » Fri Aug 30, 2013 12:05 pm

Hi,

Do you have a simple example so we can see in what exact circumstances there's a crash?
Best Regards,
ImageYeray Alonso
Development & Support
Steema Software
Av. Montilivi 33, 17003 Girona, Catalonia (SP)
Image Image Image Image Image Image Please read our Bug Fixing Policy

h.hasenack
Newbie
Newbie
Posts: 7
Joined: Mon May 13, 2013 12:00 am

Re: Shape data editor causes AV

Post by h.hasenack » Mon Sep 09, 2013 7:24 am

Sample app, data and steps to reproduce mailed to support*at*steema.com

-----
  • Compile the app (the provied exe already as my patches!)
  • Use the app to load the provide shape file
  • Open the chart editor, open map series
  • Browse to the shapes list -> crash

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

Re: Shape data editor causes AV

Post by Narcís » Mon Sep 09, 2013 7:30 am

h.hasenack wrote:Sample app, data and steps to reproduce mailed to support*at*steema.com
Please send it to info at steema dot com with a reference to this thread. The support email address is disabled.

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

h.hasenack
Newbie
Newbie
Posts: 7
Joined: Mon May 13, 2013 12:00 am

Re: Shape data editor causes AV

Post by h.hasenack » Tue Sep 10, 2013 9:02 am

DOne

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

Re: Shape data editor causes AV

Post by Narcís » Tue Sep 10, 2013 11:41 am

Hello,

Thanks for your email. I could reproduce the bug (TV52016712) here and implemented your fix suggestion like this:

Code: Select all

  if Assigned(OldCanvas3D) and Assigned(ASeries.ParentChart) then
  begin
    {$IFNDEF AUTOREFCOUNT}
    ASeries.ParentChart.Canvas.Free;
    {$ENDIF}

    TCustomChart(ASeries.ParentChart).InternalCanvas:=OldCanvas3D;
  end;
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

h.hasenack
Newbie
Newbie
Posts: 7
Joined: Mon May 13, 2013 12:00 am

Re: Shape data editor causes AV

Post by h.hasenack » Tue Sep 10, 2013 12:59 pm

Thx. I guess it'' be in the official XE5 release then.. :)

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

Re: Shape data editor causes AV

Post by Narcís » Tue Sep 10, 2013 1:44 pm

Hello,

Yes!
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