Access violations C++ Builder Rio and Android

TeeChart FireMonkey (Windows,OSX,iOS & Android) for Embarcadero RAD Studio, Delphi and C++ Builder (XE5+)
Post Reply
relayman
Newbie
Newbie
Posts: 20
Joined: Tue Jun 25, 2019 12:00 am

Access violations C++ Builder Rio and Android

Post by relayman » Wed Aug 07, 2019 12:21 am

Hi,

I have a resize function that adjusts chart height/width and position on form, it works fine. Today i tried to add ability to toggle bottom axis labels on/off. ChartName->BottomAxis->Labels = true; (or = false) causes an access violation on Android. Works fine on iOS.

Is this a known bug? The only series on the chart are TFastLineSeries.

UPDATE: I ran across another one. ChartName->Legend->Visible = true; (or = false). Works as expected on iOS but causes access violation on Android (os ver 9). I'm hoping that C++ is not an afterthought here...the lack of C++ examples makes me think it may be.

thanks,
russ

p.s. Embarcadero® C++Builder 10.3 Version 26.0.33219.4899

Marc
Site Admin
Site Admin
Posts: 1272
Joined: Thu Oct 16, 2003 4:00 am
Location: Girona
Contact:

Re: Access violations C++ Builder Rio and Android

Post by Marc » Tue Aug 13, 2019 2:12 pm

Hello Russ,

Sorry for the delay replying.

I've tried your test code in an Android project, SDK 25, running from RAD Studio 10.3.2. The property executes correctly at runtime.

(Embarcadero® C++Builder 10.3 Version 26.0.34749.6593)

Are there any other clues that may help us reproduce the issue? This may be related to the version of RAD Studio.

ChartName->Legend->Visible = false/true; also runs correctly.

Regards,
Marc Meumann
Steema Support

relayman
Newbie
Newbie
Posts: 20
Joined: Tue Jun 25, 2019 12:00 am

Re: Access violations C++ Builder Rio and Android

Post by relayman » Sun Sep 01, 2019 7:02 pm

Hi Marc,

Sorry, just now saw your reply. No, the simple code above caused the access violation. In fact, I've had quite a few problems - including one now that i can't figure how to stop. After i've created several charts - the app will spontaneously crash. I'm putting the charts in a TScrollBox so i can move them around etc. Works fine, except the unexpected crashes. Can't debug it either...

So, i'm wondering if i'd be better off to dive into Delphi and stop building my app it C++. It seems the charts are much better behaved in Delphi? Is that fair assessment?

thanks,
russ

p.s. Is there a way to stop the chart from doing anything after being initially created? I'm thinking some "recalculation" must be going on in the background for it to just go belly up without being manipulated.

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

Re: Access violations C++ Builder Rio and Android

Post by Yeray » Mon Sep 02, 2019 8:20 am

Hello,

I can't say if you should continue using C++ or move to Delphi.
We use Delphi to develop TeeChart VCL/FMX and the tools associated with it. So we don't have enough experience in C++ to give you an impartial opinion.

Regarding the error you are getting and the impression you have that TeeChart is doing something in the background, you could try to disable the zoom, scroll and hover features:

Code: Select all

  Chart1.AllowPanning:=pmNone;
  Chart1.AllowZoom:=False;
  Chart1.Hover.Hide;
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

relayman
Newbie
Newbie
Posts: 20
Joined: Tue Jun 25, 2019 12:00 am

Re: Access violations C++ Builder Rio and Android

Post by relayman » Tue Sep 03, 2019 1:43 am

Hi Yeray,

I've spent the day on a memory leak error (the minor Android issues i'll get back to). I can create one or more TeeChart's on a TScrollBox in my FMX app (i have a nice template chart that i just clone and add series to). It works fine - except, if i start scrolling up/down or left/right to see all of the charts and to see entire chart (horizontally) i start gobbling up memory. I'm watching my app performance via Xcode Console to see the messages. I'll eventually get a "Received memory warning" for my app and then it kills my app and gives me a kernal message, "EXC_RESOURCE -> myappname[5548] exceeded mem limit: ActiveHard 1400MB (fatal)". This does not occur when i run my app on Win32 - very stable memory usage.

On iOS If i just plot the charts and leave it alone no crash. But, that is obviously not a solution.
To get the scroll capability (so i can go from x=0 to x = last sample) on my chart i'm putting the charts in a TScrollBox. [b]Is there another way to get a left/right scroll capability with the TeeChart i can try?[/b] I've attached a zip of my chart code showing how i clone the template and then add points to the required series. thanks, russ [attachment=1]snip3.jpg
Attachments
chart_code.zip
(1.65 KiB) Downloaded 1475 times
snip3.jpg
snip3.jpg (14.88 KiB) Viewed 30653 times

relayman
Newbie
Newbie
Posts: 20
Joined: Tue Jun 25, 2019 12:00 am

Re: Access violations C++ Builder Rio and Android

Post by relayman » Tue Sep 03, 2019 1:47 am

Forgot to mention that i'm using registered version of TeeChartVCLFMXStandard-2019.27 and i'm building in C++Builder in Rad Studio (10.3.2).

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

Re: Access violations C++ Builder Rio and Android

Post by Yeray » Thu Sep 05, 2019 1:14 pm

Hello,

There are variables not initialized in the code snipped you attached.
Please arrange a simple example project we can run as-is to reproduce the problem here.
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

relayman
Newbie
Newbie
Posts: 20
Joined: Tue Jun 25, 2019 12:00 am

Re: Access violations C++ Builder Rio and Android

Post by relayman » Thu Sep 05, 2019 2:20 pm

Thanks Yeray - since the topic shifted to the memory leak i made a new thread, "memory leak on iOS with teechart (FMX, C++)".

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

Re: Access violations C++ Builder Rio and Android

Post by Yeray » Fri Sep 06, 2019 6:22 am

Ok, thanks for clarifying.
We'll reply you there as soon as possible.
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

Post Reply