![]() | Steema Issues DatabaseNote: This database is for bugs and wishes only. For technical support help, if you are a customer please visit our online forums;otherwise you can use StackOverflow. Before using this bug-tracker we recommend a look at this document, Steema Bug Fixing Policy. |
| Summary: | Crash after export to metaFile, if CursorTool->Active set to false | ||
|---|---|---|---|
| Product: | VCL TeeChart | Reporter: | garethtyeparc |
| Component: | Tools | Assignee: | Steema Issue Manager <issuemanager> |
| Status: | RESOLVED FIXED | ||
| Severity: | critical | CC: | david, sandra |
| Priority: | --- | ||
| Version: | 131119 | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Windows | ||
| Chart Series: | --- | Delphi / C++ Builder RAD IDE Version: | |
| Attachments: | Simple C++builder project to reproduce error | ||
The problem only occurs if you have GDI+ mode activate. In Delphi occurs, too. Delphi Code: uses Series, TeExport; procedure TForm1.FormCreate(Sender: TObject); begin Chart1.AddSeries(TLineSeries).FillSampleValues; end; procedure TForm1.Button1Click(Sender: TObject); begin TeeExport(Self, Chart1); end; Fixed. After creating the Metafile (using a TMetafileCanvas), the problem was the "real" GDI+ chart canvas still had a wrong reference to the metafile canvas at its private "IXorCanvas" variable (used to draw the zoom rectangle when clicking and dragging a chart) |
Created attachment 73 [details] Simple C++builder project to reproduce error Access violation occurs after exporting chart as metafile with the TCusorTool "Active" property set to false. C++Builder XE4, TeeChartPro 131119 Windows 7 64bit Steps to reproduce: 1) Create new VCL Project 2) Add TChart and add line series (Series1) 3) Add TCursorTool (ChartTool1) 4) Add OnFormCreate event to Form1 and add following to void TForm1::FormCreate() Series1->FillSampleValues(50); ChartTool->Active = false; 5) Add TButton to Form1 (Button1) 6) Add OnClick Event and add following to void TForm1::Button1Click() TeeExport( this, Chart1 ); 7) In Export Chart dialog box select "as Metafile" in Format list box and then press "Preview..." button close preview and close dialog box 8) Click on Chart1 then get Access Violation.