I have been using FlexCel with both Win32 and Win64.
Now that I am using C++Builder 12.3 when:
xlsx->AutofitCol(1, xlsx->GetColCount(xlsx->ActiveSheet), false, 1.0);
is called.
The error is:
First chance exception at $00007FFF482985EA. Exception class Exception with message 'FlexCel render engine has not been initialized for the current platform. Make sure you add "uses FlexCel.Render" to your uses list'. Process Project1.exe (17764).
I include the following: #include <FlexCel.VCLSupport.hpp> #include <FlexCel.Core.hpp> #include <FlexCel.XlsAdapter.hpp> #include <FlexCel.Render.hpp>
This call works for Win32 & Win64 - just not Win64X.
The if defined lines are not really needed, but there is also no need to call this in win32 and win64 (because as you said, that works), so putting the initialization code between defines that only activate in win64x looks better.
We are planning to add a workaround for our next release, if Embarcadero doesn't fix this first. But at the moment we are just waiting to see if embarcadero fixes it.
Thanks Adrian - that worked once I rebuilt everything.
The main trouble I have had with Win32X is unit initialisation order. The old tool chains seemed to work out any dependencies between global variables in different modules / units with no problems. Maybe I had just been lucky with this until now.
I do have some Delphi units in my C++Builder project as well, so I will keep your bug report in mind.