I am facing an issue where most exceptions thrown in my .NET MAUI Windows app appear in the Windows Event Viewer as if they are coming from CoreMessagingXP.dll instead of showing the actual managed exception details.
Event Viewer Entry
Example error entry in Event Viewer:
Faulting application name: MyApp.exe, version: 1.0.0.0, time stamp: 0x68760000
Faulting module name: CoreMessagingXP.dll, version: 10.0.26107.1011, time stamp: 0x76d08d1d
Exception code: 0xc000027b
Fault offset: 0x0000000000093b76
Faulting process id: 0x0x91EC
Faulting application start time: 0x0x1DC20AF5C927FCB
Faulting application path: E:\WS\MyApp\bin\Debug\net9.0-windows10.0.19041.0\win10-x64\AppX\MyApp.exe
Faulting module path: C:\Program Files\WindowsApps\Microsoft.WindowsAppRuntime.1.7_7000.522.1444.0_x64__8wekyb3d8bbwe\CoreMessagingXP.dll
Report Id: 0575b91c-aca3-4212-acae-73681ff068e0
Faulting package full name: com.company.myapp_0.0.1.0_x64__yx3b1xs067x9a
Faulting package-relative application ID: App
Reproduction
For testing, I simply threw an exception from the code-behind of a button click. Even in this trivial case, the Event Viewer still shows the crash as CoreMessagingXP.dll.
Debugging the Dump
When I open the generated dump file in Visual Studio, it breaks at KERNELBASE.dll with:
Unhandled exception at 0x00007FFCC8D13B76 (CoreMessagingXP.dll) in MyApp.exe:
0xC000027B: An application-internal exception has occurred (parameters: 0x000001B1B7019A10, 0x0000000000000001).
Call Stack (excerpt):
> KERNELBASE.dll!00007ffd369321b2() Unknown
combase.dll!00007ffd383d5e79() Unknown
CoreMessagingXP.dll!00007ffcc8d13b76() Unknown
CoreMessagingXP.dll!00007ffcc8cc0aad() Unknown
CoreMessagingXP.dll!00007ffcc8cc4b06() Unknown
...
Microsoft.WinUI.dll!Microsoft.UI.Xaml.Application.Start(...) Unknown
MyApp.dll!MyApp.WinUI.Program.Main(string[] args) Unknown
Questions
- Why does the actual managed exception not show up in the Windows Event Log or the dump file?
- How can I configure my MAUI Windows app so that managed exceptions are properly logged and visible in Event Viewer and dumps, instead of being masked as a generic
CoreMessagingXP.dllcrash?

