尝试导航到Windows Phone 8.1应用程序中的页面时,我遇到了一个非常奇怪的异常(通用)
A first chance exception of type 'Windows.UI.Xaml.Markup.XamlParseException' occurred in MyApplcation.exe
WinRT information: Cannot create instance of type '%0' [Line: 25 Position: 44]
它还说:
The text associated with this error code could not be found.
我的MainPage.xaml.cs中有一些代码导航到一个名为details的页面:
private void Button_Click(object sender, RoutedEventArgs e)
{
Frame.Navigate(typeof(Details));
}
详细信息代码非常少:
<Page
x:Class="MyApplcation.Views.Details"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="using:MyApplcationViews"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:mmppf="using:Microsoft.PlayerFramework"
mc:Ignorable="d"
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">
<Page.Resources>
</Page.Resources>
<Grid>
<Rectangle Fill="#FF152853" HorizontalAlignment="Left" Height="260" VerticalAlignment="Top" Width="491" Name="videoBack"/>
<Image x:Name="preview_image" HorizontalAlignment="Left" Height="260" Margin="0,10,0,0" VerticalAlignment="Top" Width="56" Stretch="UniformToFill"/>
<Border x:Name="layoverBorder" CornerRadius="50" BorderBrush="Transparent" BorderThickness="2" Margin="196,63,196,689" Background="#FFFEFEFE" Opacity="1" >
<Image x:Name="layoverImage" HorizontalAlignment="Left" Height="51.671" Margin="20,14.674,0,0" VerticalAlignment="Top" Width="56.372" Source="ms-appx:///Assets/triangle-64 (2).png" Stretch="None" RenderTransformOrigin="0.5,0.5" UseLayoutRounding="False" d:LayoutRounding="Auto">
<Image.RenderTransform>
<CompositeTransform Rotation="90.899"/>
</Image.RenderTransform>
</Image>
</Border>
<mmppf:MediaPlayer x:Name="player" Source="{Binding Video}" Margin="0,0,0,587"/>
</Grid>
</Page>
当我删除<mmppf:MediaPlayer...
行时,页面导航正常工作。
我不知道从哪里开始,因为抛出的异常是如此模糊。