What TChart.Canvas class is being used?
Posted: Fri Aug 08, 2014 2:07 pm
For a long time, I had the following code:
This code gets called a lot (used to create an image of a chart for reporting). But a few days ago the Assert fired.
How can I know what class is used by default for the TChart.Canvas object?
Ed Dressel
Code: Select all
Assert(aChart.Canvas is TGDIPlusCanvas, 'Chart canvas class should be TGDIPlusCanvas but is ' + aChart.Canvas.ClassName);
aChart.Canvas := TTeeCanvas3D.Create;
try
...
finally
aChart.Canvas := TGDIPlusCanvas.Create;
end;
How can I know what class is used by default for the TChart.Canvas object?
Ed Dressel