Hi there
This code is not working:
LongListSelectorControl.Dispatcher.BeginInvoke(() =>
{
IEnumerable list = newFeed.Items.Where( i => i != null).ToList();
MainFeedListBox.ItemsSource = list;
});
Getting an "Invalidcastexception at Microsoft.Phone.Controls.LongListSelector.FlattenData()",
any suggestions?
Comments: ** Comment from web user: AdamDavidHill **
This code is not working:
LongListSelectorControl.Dispatcher.BeginInvoke(() =>
{
IEnumerable list = newFeed.Items.Where( i => i != null).ToList();
MainFeedListBox.ItemsSource = list;
});
Getting an "Invalidcastexception at Microsoft.Phone.Controls.LongListSelector.FlattenData()",
any suggestions?
Comments: ** Comment from web user: AdamDavidHill **
@richard_szalay - Great catch! IsFlatList="true" fixed it for me. Annoyingly this doesn't appear to be required for WP8, but when back porting my app to WP7 I ran into this. Thanks.