TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Anele Ngqandu
1.3k
429
27.8k
Get selected items from listview object sender xamarin
Nov 13 2017 2:47 AM
Hi
Using ListView Behaviors, How do I get values/object of selected item or selected row?
Below is what i tried and I get a property that says "SelectedItem" but i cant access it. What am I missing?
<ListView.Behaviors>
<behaviors:EventHandlerBehavior EventName="ItemSelected">
<behaviors:InvokeCommandAction Command="{Binding OnItemSelected}" /> </behaviors:EventHandlerBehavior> </ListView.Behaviors>
//constructor
public BurialsViewModel()
{
_onItemSelected = new Command(OnSelectedItem);
}
//ViewModel
ICommand _onItemSelected;
public ICommand OnItemSelected{ get { return _onItemSelected; } }
void OnSelectedItem(object sender) { //I need values from sender }
Reply
Answers (
0
)
XAMARIN Infinite Scrolling ListView using android Blank App
How to obtain url and title from customTabsChrome