question

HemanthB-9452 avatar image
0 Votes"
HemanthB-9452 asked HemanthB-9452 commented

Microsoft.UI.Xaml.Markup.XamlParseException: 'XAML parsing failed.' - WinAppSDK 1.1 Preview 2

197801-image.png


Please help. I am using a WinUI 3 Unpackaged app WindowsAppSDK 1.1 Preview 2

windows-app-sdk
image.png (112.2 KiB)
· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Could you please show a minimal, reproducible sample without private information?

0 Votes 0 ·

I actually found out the error in my MainWindow.xaml file.

0 Votes 0 ·

1 Answer

Castorix31 avatar image
1 Vote"
Castorix31 answered

This error can happen if there is a bug in MainWindow.xaml not detected by the XAML compiler

For example, if I set a wrong resource, like

 <Grid Background="{ThemeResource ApplicationPageBackgroundThemeBrush2}">

instead of

 <Grid Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">

I get this error

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.