1
Vote

Crash on Device (not on emulator) when starting the Pivot control.

description

When I try to view one of the items that opens the pivot control, I get the following error on the device:
This is not reproducible on the emulator. This is reproducible on other devices, and failed certification.
 
Right before the XamlParseException, I also received the following message in output:
 
A first chance exception of type 'System.FormatException' occurred in mscorlib.dll
'UI Task' (Managed): Loaded 'System.SR.dll'
A first chance exception of type 'System.Xml.XmlException' occurred in System.ServiceModel.Web.dll
A first chance exception of type 'System.Xml.XmlException' occurred in System.ServiceModel.Web.dll
'UI Task' (Managed): Loaded 'System.Windows.debug.resources.dll'
System.Windows.Data Error: BindingExpression path error: 'SelectedPivotIndex' property not found on 'Quandtm_News.Pages.Pivot.PivotPageViewModel' 'Quandtm_News.Pages.Pivot.PivotPageViewModel' (HashCode=109367337). BindingExpression: Path='SelectedPivotIndex' DataItem='Quandtm_News.Pages.Pivot.PivotPageViewModel' (HashCode=109367337); target element is 'Microsoft.Phone.Controls.Pivot' (Name='ListPivot'); target property is 'SelectedIndex' (type 'System.Int32')..
 
If I remove "SelectedPivotIndex" from the xaml, it still gives the following exception right after the 2x XmlExceptions:
 
System.Windows.Markup.XamlParseException occurred
Message=AG_E_PARSER_BAD_TYPE [Line: 7 Position: 8]
LineNumber=7
LinePosition=8
StackTrace:
   at MS.Internal.XcpImports.CheckHResult(UInt32 hr)
   at MS.Internal.XcpImports.FrameworkElement_MeasureOverride(FrameworkElement element, Size availableSize)
   at System.Windows.FrameworkElement.MeasureOverride(Size availableSize)
   at System.Windows.FrameworkElement.MeasureOverride(IntPtr nativeTarget, Single inWidth, Single inHeight, Single& outWidth, Single& outHeight)
   at MS.Internal.XcpImports.MeasureOverrideNative(IntPtr element, Single inWidth, Single inHeight, Single& outWidth, Single& outHeight)
   at MS.Internal.XcpImports.FrameworkElement_MeasureOverride(FrameworkElement element, Size availableSize)
   at System.Windows.FrameworkElement.MeasureOverride(Size availableSize)
   at System.Windows.FrameworkElement.MeasureOverride(IntPtr nativeTarget, Single inWidth, Single inHeight, Single& outWidth, Single& outHeight)
   at MS.Internal.XcpImports.MeasureOverrideNative(IntPtr element, Single inWidth, Single inHeight, Single& outWidth, Single& outHeight)
   at MS.Internal.XcpImports.FrameworkElement_MeasureOverride(FrameworkElement element, Size availableSize)
   at System.Windows.FrameworkElement.MeasureOverride(Size availableSize)
   at System.Windows.FrameworkElement.MeasureOverride(IntPtr nativeTarget, Single inWidth, Single inHeight, Single& outWidth, Single& outHeight)
   at MS.Internal.XcpImports.MeasureOverrideNative(IntPtr element, Single inWidth, Single inHeight, Single& outWidth, Single& outHeight)
   at MS.Internal.XcpImports.FrameworkElement_MeasureOverride(FrameworkElement element, Size availableSize)
   at System.Windows.FrameworkElement.MeasureOverride(Size availableSize)
   at Microsoft.Phone.Controls.PhoneApplicationFrame.MeasureOverride(Size availableSize)
   at System.Windows.FrameworkElement.MeasureOverride(IntPtr nativeTarget, Single inWidth, Single inHeight, Single& outWidth, Single& outHeight)

comments