Testing with a .NET 8.0 release candidate has shown that an error can occur in certain circumstances. If an app uses the synrnt 12.2.1.1008 or earlier NuGet package and targets ".NET 8.0 Windows," it may crash if it attempts to access UI Toolkit or the low-level Synergy windowing API (the W_ routines). For example,
Unhandled exception. System.Runtime.InteropServices.SEHException (0x80004005): External component has thrown an exception.
at Synergex.SynergyDE.SynRTL.dw_updt(Void* wnd, DESCRIP** descr)
at Synergex.SynergyDE.SysRoutines.s_w_updt()
at _NS_wndtestcorewin._CL.MAIN$WNDTEST(String[] args) in ...
Apps targeting ".NET 8.0" instead of ".NET 8.0 Windows" shouldn\'t be affected, nor should apps that target earlier versions of .NET or that don\'t use either UI Toolkit or the windowing API.
The error appears to be caused by a mismatch in framework versions between synwnd.runtimeconfig.json and *appname*.runtimeconfig.json. We expect to resolve this in an upcoming release. In the meantime, you can work around the error by modifying the copy of synwnd.runtimeconfig.json so that the .NET versions match those in the runtimeconfig.json file for your app. For example,
{
"runtimeOptions": {
"tfm": "net8.0",
"frameworks": [
{
"name": "Microsoft.NETCore.App",
"version": "8.0.0-rc.2.23479.6"
},
{
"name": "Microsoft.WindowsDesktop.App",
"version": "8.0.0-rc.2.23479.10"
}
],
"configProperties": {
"System.Reflection.Metadata.MetadataUpdater.IsSupported": false
}
}
}
Note that the "version" values should exactly match the values in the runtimeconfig.json file for your app, which may be different than the ones in this example. Also note that the "frameworks" array should keep that name, even if the app\'s runtimeconfig.json file says "includedFrameworks."
Other potential workarounds are to remove your app\'s runtimeconfig.json file or to edit it so its values match those in synwnd.runtimeconfig.json.