Open Khaos66 opened 5 months ago
Two suggestions:
preamble()
in RetryHelper.TryCallAction
in a try..catch
, too. And ignore the exception.Speller.OnIdle
check if the thread is actually able to call COM and evade RPC_E_CANTCALLOUT_ININPUTSYNCCALL
Reference https://stackoverflow.com/questions/54204493/wpf-spell-check-causes-exceptions-on-some-machines
And the {7AB36653-1796-484B-BDFA-E74F1DB7C1DC}
is the Microsoft Spell Checker Factory Class.
Description
On some machines our app is logging this unhandled dispatcher exception a lot:
Reproduction Steps
Our app is quite complex. It uses WPF only for the UI. It includes an
ElementHost
, that is included via COM.Expected behavior
No exception
Actual behavior
COMException is thrown in
preamble
action, even thoughignoredException
includesCOMException
See https://github.com/dotnet/wpf/blob/63a9081957decc475c6fd9a6ccd960f4fda3dfbc/src/Microsoft.DotNet.Wpf/src/PresentationFramework/System/Windows/Documents/MsSpellCheckLib/Utils/RetryHelper.cs#L137Regression?
No response
Known Workarounds
No response
Impact
No response
Configuration
.NET 4.8.1 Windows Server 2016 (x64)
Other information
Only happens on some machines