On 2011-03-21 04:38:46 +1000, Alexander Klenin wrote: > 2011/3/21 Michael Van Canneyt <[email protected]>: > >> Yes, but, how can I use a TCanvas in a CGI app? > >> > >> If I write: > >> > >> Chart.PaintOnCanvas(TCanvas(lCanvas), Rect(0, 0, 100, 100)); > >> > >> I get an Access Violation. > > Of course, since you are converting an object to the type it does not belong > to. > You should create a TBitmap or another similar object. > Did you look at the savedemo as I proposed in a previous mail?
Yes, if I try to PaintOnCanvas of a TBitmap, for example. I get "Canvas does not allow drawing". > > > Simply said: you can't. > > The current TAChart is not suitable for a CGI application. It expects a GUI. > I'm afraid Michael is right. -- Leonardo M. Ramé http://leonardorame.blogspot.com -- _______________________________________________ Lazarus mailing list [email protected] http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
