使用 Fontsize、FontAttributes 和 HorizontalOptions 时出现未处理的异常错误
unhandled exception error when using Fontsize, FontAttributes and HorizontalOptions
下面的代码由于某种原因被破坏了,但是当我删除 FontSize="Large" FontAttributes="Bold"
HorizontalOptions="Center",效果很好。它抛出一个未处理的异常,我无法部署到模拟器。为什么?
<ContentPage.Content>
<ListView x:Name="GrouppedList"
ItemsSource="{Binding Rss.channel.item}">
<ListView.ItemTemplate>
<DataTemplate>
<TextCell Text="{Binding title}" Detail="{Binding description}" FontSize="Large" FontAttributes="Bold"
HorizontalOptions="Center" />
</DataTemplate>
</ListView.ItemTemplate>
</ListView>
</ContentPage.Content>
FontAttributes、FontSize 和 HorizontalOptions 不是 TextCell 的属性。如果您想进一步自定义它,您需要转到 ViewCell。
下面的代码由于某种原因被破坏了,但是当我删除 FontSize="Large" FontAttributes="Bold" HorizontalOptions="Center",效果很好。它抛出一个未处理的异常,我无法部署到模拟器。为什么?
<ContentPage.Content>
<ListView x:Name="GrouppedList"
ItemsSource="{Binding Rss.channel.item}">
<ListView.ItemTemplate>
<DataTemplate>
<TextCell Text="{Binding title}" Detail="{Binding description}" FontSize="Large" FontAttributes="Bold"
HorizontalOptions="Center" />
</DataTemplate>
</ListView.ItemTemplate>
</ListView>
</ContentPage.Content>
FontAttributes、FontSize 和 HorizontalOptions 不是 TextCell 的属性。如果您想进一步自定义它,您需要转到 ViewCell。