Jim Bennett (83) [Avatar] Offline
#1
There are a number of moving parts when it comes to building mobile apps using Xamarin, including different Visual Studio and Xamarin versions, Xcode, and the various Android SDKs. There is also different versions of MvvmCross to consider as well when using this to build cross-platform apps.

This thread is designed to highlight known issues with different versions and give workarounds.

MvvmCross 5.2.0
There are two known issues with MvvmCross 5.2.0:

Crash on startup
When you launch your app it may crash with an MvxException, failing to construct the CountersViewModel.
The Messenger plugin NuGet package is meant to install a bootstrapper file-a class that ensures the messenger is registered with the IoC container, but with newer project types this file is not created correctly. If you see this exception, create a folder called Bootstrap in the Android and iOS app projects, and add a class called MessengerPluginBootstrap to that folder containing add the following:

using MvvmCross.Platform.Plugins;

namespace Countr.Droid.Bootstrap
{
   public class MessengerPluginBootstrap
      : MvxPluginBootstrapAction<MvvmCross.Plugins.Messenger.PluginLoader>
   {
   }
}


substituting iOS for Droid for the iOS app.

Hang on startup
The Initialize method can hang when awaiting async methods, such as when you await the call to LoadCounters in CountersViewModel. The fix is to update to MvvmCross 5.2.1 or later.