Search code examples
xamlvisual-studio-2015windows-phone-8.1designerxamlparseexception

XamlParseException when using the XAML Designer


Important: Consider every tag in the .xaml codes below closed


I've searched everywhere for the answer but none of the questions in this website (or the MSDN website) solved it. Everytime I create a new Windows Phone 8.1 project I get the XamlParseException, even when I choose the Blank App project. I will list everything I tried.

  • Reinstall VS 2015
  • Reinstall VS 2015 without the SDK and then download it later with the emulators
  • Enable Developer Mode on Windows
  • Disable Project Code
  • Open the .xaml files with the Automatic Editor Selector and XAML Designer
  • Enable XAML Designer in the Options, of course
  • Update Windows 10 (note: I couldn't upgrade to 1809, I'm stuck with 1803)
  • Enable Hypervisor on the BIOS
  • Reboot computer
  • Adding the 'ThemeResources.xaml' manually on the project
  • Build, Rebuild and Clean the solution
  • Using different .NET Framework versions

Here is my App.xaml code:

<Application
x:Class="App2.App"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="using:App2">

Here is my MainPage.xaml code:

<Page
x:Class="App2.MainPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="using:App2"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
mc:Ignorable="d"
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">

<Grid>

</Grid>


Solution

  • I got it to work just by updating to Windows 10 1089, don't forget to enable Developer Mode once you upgrade, since "Sideload Apps" isn't enough.