0
votes

I started a project in Xamarin Studio on my mac. The project was a Xamarin.Forms app for iOS and Android. It is a simple app, like the Todo sample app, which shows a list of objects, then when a user selects an object it shows the details page. This works as expected on iOS and Android.

I then followed the steps "Adding a Universal Windows Platform (UWP) App" and believe everything is set up correctly. I've compared most of the settings and code changes to the Todo sample app, since it seemed to do what I wanted for the most part.

The interesting thing, however, is that when I run the app on "Local Machine" or one of the mobile emulators, the ItemSelected event never fires when I select an item from the list (only on the UWP runs.)

Does anyone have any ideas for how I can figure out why it isn't called (just on UWP) and how I can fix it?

That being said, I also have a button in the top bar that allows me to create a new item. This button works fine in all platforms (iOS, Android, Windows 10), and I'm seeing the data that I populate and pull from a SQLite database, so I can see that things are working correctly; except for this event firing.

Also, if it helps, all my code for the XAML and .cs files are done in the portable project. I'm following the PCL pattern for my project setup.

1

1 Answers

0
votes

I gave up ItemSelected and replaced it with ListViewItemTappedAttached from the below link. It works well on all platforms (UWP included) and it's easier than ItemSelected especially in a MVVM framework.
https://github.com/XAM-Consulting/FreshEssentials