0
<ListView ItemsSource="{Binding PageViewModel.TestCollection, Mode=OneWay}">
<ListView.ItemTemplate>
<DataTemplate x:DataType="local:TestClass">
<TextBlock >Blah</TextBlock>
</DataTemplate>
</ListView.ItemTemplate>
<ItemsControl.ItemsPanel>
<ItemsPanelTemplate>
<CarouselPanel />
</ItemsPanelTemplate>
</ItemsControl.ItemsPanel>
</ListView>
只是想與此控件進行實驗。它建立但掛在App.g.i.cs部署期間:CarouselPanel在UWP拋出異常
#if DEBUG && !DISABLE_XAML_GENERATED_BREAK_ON_UNHANDLED_EXCEPTION
UnhandledException += (sender, e) =>
{
if (global::System.Diagnostics.Debugger.IsAttached) global::System.Diagnostics.Debugger.Break();
};
我試過幾種類型的集合,但得到相同的錯誤。
當Visual Studio在UnhandledException處理程序中觸發break時,可以將鼠標懸停在'(sender,e)'部件中的'e'參數表上並查看發生的確切異常。請做到這一點,並更新後的細節關於這個例外。 –