我想在Windows应用商店中访问非公开会员,但我不能。
我想访问图片中的“元素”
我有GridView
绑定到集合以进行分组,如下所示
private void gridview_1_SelectionChanged(object sender, SelectionChangedEventArgs e)
{
slidein_history_of_illness.DataContext = (sender as GridView).SelectedItem;
object obj = (sender as GridView).SelectedItem;
}
ItemSource
的{{1}}为GridView
:
GridViewItemSoure
答案 0 :(得分:0)
我解决了!
我用这行来访问元素!
private void gr_SelectionChanged(object sender, SelectionChangedEventArgs e)
{
object obj = (sender as GridView).SelectedItem;
IGrouping<string, object> groupCast = obj as System.Linq.IGrouping<string, object>;
foreach (Item item in groupCast)
{
//to do staff
}
}