InsertImage offset does not work for Excel97 format
Posted: Tue Apr 10, 2018 3:19 pm
Below code should insert an image at halfway in the first cell's row and column (0.5, 0.5). It works for Excel2007 format, but not for Excel97.
For Excel97 format, it seems to round up the offset to the closest cell and actually inserts at (1.0, 1.0).
Code: Select all
XLS := TXLSReadWriteII5.Create(self);
XLS.Version := xvExcel97;
XLS.Sheets[0].Drawing.InsertImage('image.jpg', 0, 0, 0.5, 0.5, 0.75);