Page 1 of 1

Using addcandle, addxyz, after loading a .tee file

Posted: Mon Oct 26, 2009 7:14 pm
by 10554436
Hi
I read about accessing a series more directly via say
mychart[0].add(blah blah)
but when using a non default series, which has more than the default data entry, eg a candle (via addcandl) or a addxyz to a surface type chart
how do you access that series directly?
because after saving and then re loading a .tee config file for those charts, using the , series1.addxyz or series1.addcandle, causes an access violation
or some other work around
thanks!
ps, great set of components, kudos!
pps, I am wanting to compile on Lazarus for the Mac...any pointers?
thanks!
Brian

Re: Using addcandle, addxyz, after loading a .tee file

Posted: Tue Oct 27, 2009 12:05 pm
by narcis
Hi Brian,
I read about accessing a series more directly via say
mychart[0].add(blah blah)
but when using a non default series, which has more than the default data entry, eg a candle (via addcandl) or a addxyz to a surface type chart
how do you access that series directly?
because after saving and then re loading a .tee config file for those charts, using the , series1.addxyz or series1.addcandle, causes an access violation
or some other work around
This is because you need to typecast the series to the series type you need, for example:

Code: Select all

  (Chart1[0] as TSurfaceSeries).AddXYZ(x, y, z);
  (Chart1[1] as TCandleSeries).AddCandle(date, open, high, low, close);
ps, great set of components, kudos!
Thank you very much :!:
pps, I am wanting to compile on Lazarus for the Mac...any pointers?
For that you need to have a TeeChart Pro v8 VCL source code license. Find attach TeeChart.lpk and compile.bat to generate your TeeChart packages for Lazarus. Please notice that you'll have to change the fixed paths at compile.bat. Also notice that probably TeeChart no longer works using latest Lazarus versions, some change broke it. We haven't been able to find a solution so far. With old Lazarus versions, previous to 0.9.24 from November 2007, should work fine.

Hope this helps!

Re: Using addcandle, addxyz, after loading a .tee file

Posted: Tue Oct 27, 2009 12:07 pm
by narcis
Hi Brian,

Sorry, I forgot the attachment :oops:. Here it is.

Re: Using addcandle, addxyz, after loading a .tee file

Posted: Tue Oct 27, 2009 5:51 pm
by 10554436
Hi
thanks for the tip on the series direct access!
I will work on that today
re Lazarus, I do have the pro 8 sources :)
re the .bat file, I will see if I can get that to work via a terminal window on the mac (changing the paths, etc)
thanks!
(I had tried to create my own package and comile the Teechartreg.pas, but ran into problems with the OS not being detected in the code and windows wanting to be used and then also other sections of code no detecting OSX )