A small proportion of users are reporting an Access Violation error during startup of my FMX Windows application. I've not been able to replicate it myself, but I have determined a number of things by sending variations to the users. Here are the facts.
- The vast majority of users do not have the issue
- All users with the issue have what looks like a normal Windows 10 setup
- The error occurs after the forms have been created but before the OnCreate events for each form start to get called. Perhaps somewhere early in Application.Run.
- The error does not occur with earlier version of my app built in Delphi 10.4.
- The error does not occur when run using Windows XP compatibility mode. This is strange since I didn't think FMX apps could run at all in Windows XP.
- I'm using one 3rd party component (FFVCL) but another app using that component and built in Delphi 11 does not cause the error.
Does anyone know of a Delphi 11.0 issue that could be causing this? Would it help for me to upgrade to 11.2? If not, can anyone suggest ideas for further investigation? Why would some apps work when built in the same version and this one doesn't? Why would it work in Windows XP compatibility mode?
Update: After updating to Rad studio 11.2, the issue is still there for those users.
Update 2: After adding call stack logging I have determined that the error occurs in FMX.Forms TFormBorder.GetSupported. The issue may be related to custom styles, which I am using on some forms. A similar question was asked previously.
App produces an exception on target computers
I assume that the error is not happening in Windows XP compatibility mode because I had only set custom styles for Win10 and Win7. I still don't understand why this only happens for a small number of users or why this became an issue when I updated from D10 to D11.