Web forum is in read-only mode. Login as active registered customer for write access
  Forum Search   New Posts New Posts

Add custom X-axis values via an event

 Post Reply Post Reply
Author
VERWAERDE Christian View Drop Down
New Member
New Member
Avatar

Joined: 12 Aug 2011
Posts: 7
Post Options Post Options   Quote VERWAERDE Christian Quote  Post ReplyReply Direct Link To This Post Topic: Add custom X-axis values via an event
    Posted: 07 Feb 2013 at 10:27am
hello,
Is it possible to get a translation of this advchart code snippet to C, as I can't get it work.
(the code which is given in this page http://www.tmssoftware.com/site/advchart.asp?s=faq)
with thanks
regards

Back to Top
Bruno Fierens View Drop Down
TMS Support
TMS Support
Avatar

Joined: 11 May 2010
Posts: 8329
Post Options Post Options   Quote Bruno Fierens Quote  Post ReplyReply Direct Link To This Post Posted: 07 Feb 2013 at 11:13am
There are many entries on this FAQ page,
what entry exactly are you referring to?
Back to Top
VERWAERDE Christian View Drop Down
New Member
New Member
Avatar

Joined: 12 Aug 2011
Posts: 7
Post Options Post Options   Quote VERWAERDE Christian Quote  Post ReplyReply Direct Link To This Post Posted: 08 Feb 2013 at 3:43am
as I stated in the title of my post : Add custom X-axis values via an event
(advcharts)
thanks

Back to Top
Pieter Scheldeman View Drop Down
TMS Support
TMS Support
Avatar

Joined: 18 May 2010
Posts: 3392
Post Options Post Options   Quote Pieter Scheldeman Quote  Post ReplyReply Direct Link To This Post Posted: 08 Feb 2013 at 11:12am
Hi, 

We have translated the code and uploaded a demo:

http://www.tmssoftware.net/public/DemoChartC.zip

Kind Regards,
Pieter
Back to Top
VERWAERDE Christian View Drop Down
New Member
New Member
Avatar

Joined: 12 Aug 2011
Posts: 7
Post Options Post Options   Quote VERWAERDE Christian Quote  Post ReplyReply Direct Link To This Post Posted: 08 Feb 2013 at 11:32am
thanks for the answer. It does not work and I get this error message:
[BCC32 Erreur] Main.cpp(525): E2034 Impossible de convertir 'void (_fastcall * (_closure )(TObject *,TChartSerie *,TCanvas *,TRect &,int,int,bool,bool &))(TObject *,TChartSerie *,TCanvas *,TRect &,int,int,bool,bool &)' en 'TChartXAxisDrawValue'
 

Back to Top
Pieter Scheldeman View Drop Down
TMS Support
TMS Support
Avatar

Joined: 18 May 2010
Posts: 3392
Post Options Post Options   Quote Pieter Scheldeman Quote  Post ReplyReply Direct Link To This Post Posted: 11 Feb 2013 at 2:47am
Which C++Builder version are you using? It works as expected here in C++Builder XE3.

Please look at the definition in AdvChart.hpp to know how to construct the event handler:

This is the definition in AdvChart.hpp generated when building the packages in XE3

typedef void __fastcall (__closure *TChartXAxisDrawValue)(System::TObject* Sender, TChartSerie* Serie, Vcl::Graphics::TCanvas* Canvas, System::Types::TRect &ARect, int ValueIndex, int XMarker, bool Top, bool &defaultdraw);
Back to Top
VERWAERDE Christian View Drop Down
New Member
New Member
Avatar

Joined: 12 Aug 2011
Posts: 7
Post Options Post Options   Quote VERWAERDE Christian Quote  Post ReplyReply Direct Link To This Post Posted: 11 Feb 2013 at 4:31am
hello again,
that did it, it was a bad definition. I use XE2.
thanks a lot
best regards

Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down