Using MBS ( “XL.Sheet.SetColumn”; $book; $sheet; 0; $colLast; -1) (here: $colLast = 10) only seems to work in some cases.
When I export all records autofit does not work.
When I export some records autofit does work in some cases.
When I export some columns autofit does work in some cases.
What causes autofit to only work in some cases? Does the data coming from FileMaker need to be formatted in a certain way? I use XL.Sheet.CellWriteText for all rows.
Using Trial Version 4.2.0. according to the excel sheet, I downloadedLibXL for Mac 5.2.0 according to the download page.
unforuntately the Mac version doesn’t have access to operating system fonts, so the autofit feature on Mac is very limited and works only for Calibri and Arial fonts.
Thank you for your help. I tried these three cases:
not setting the font
setting the font to Calibri
setting the font to Arial
In all cases I receive an Excel document with the desired font (no font → Calibri) both on Mac and Windows. But Auto Fit again works only on Windows. Example:
Set Variable [ $SchriftNormal; Value:MBS( "XL.Book.AddFont"; $book) ]
Set Variable [ $r; Value:MBS( "XL.Font.SetName"; $book; $SchriftNormal; "Arial") ]
Is there another, more “general” way of setting the fonts of the whole document to Calibri or Arial?
Also please note that the Auto Fit feature won’t work properly for all cells if your LibXL works in the trial mode. Just write an empty workbook, open it in Excel and check the trial banner at the first row.