问题描述
所以我有一个 LongListSelector 很快就会绑定到一个对象列表.
So I have a LongListSelector that will soon be bound to a list of object.
我想要的是,当点击 LongListSelectorItems 之一时,我可以点击特定对象,并且能够将该对象传递到另一个屏幕,以便我可以显示有关该对象的完整信息
What I want is when one of the LongListSelectorItems is tapped that I get the specific object tapped, and have the ability to pass that object to another screen so I can show full information about the object
private void PeopleList_Tap_1(object sender, System.Windows.Input.GestureEventArgs e)
{
MessageBox.Show("SUCCESS");
}
我的 Tap 正在工作,我只是不知道如何获取选定的对象,或者如何使用 NavigationService 将其传递到另一个页面
My Tap is working, I just don't know how to get the object that was selected, or how to pass it to another page using NavigationService
推荐答案
您可以使用 SelectionChanged
事件和 LongListSelector.SelectedItem
属性来获取所选项目.
You can use SelectionChanged
event and LongListSelector.SelectedItem
property to get selected item.
这篇关于如何从 WP8 中的 LongListSelector 项获取数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!