title: Exception when starting a MvvmCross Uwp app: "System.AccessViolationException: Attempted to read or write protected memory"
body: <p>I am trying to use MvvmCross to create a Windows Universal App, with the latest UWP bits (RTM).  In App.xaml.cs, when I attempt to run -</p>
  
  <pre><code>var start = Mvx.Resolve&lt;IMvxAppStart&gt;();
  start.Start();
  </code></pre>
  
  <p>I get a "System.AccessViolationException" -</p>
  
  <pre><code>Message: "Attempted to read or write protected memory. This is often an indication that other memory is corrupt"
  </code></pre>
  
  <p>I've created a sample project to reproduce the problem, it contains -</p>
  
  <ul>
  <li>A Portable Class Library (Test.NewCore), which targets ".NET Framework 4.6" and "Windows 10".</li>
  <li>A "Universal Windows" app (Test.Uwp), which targets "Windows 10 (10.0; Build 10240)"</li>
  <li>I am using the latest nuget pre-release packages, "MvvmCross 4.0.0-beta3" and I believe I set it up properly (I looked at the examples here: <a href="https://github.com/MvvmCross/MvvmCross/tree/4.0/nuspec" rel="nofollow">https://github.com/MvvmCross/MvvmCross/tree/4.0/nuspec</a></li>
  </ul>
  
  <p>You can download the test project here: <a href="http://1drv.ms/1G6w2m3" rel="nofollow">http://1drv.ms/1G6w2m3</a></p>
  
  <p>The full stack trace is below -</p>
  
  <pre><code>System.AccessViolationException was unhandled
    HResult=-2147467261
    Message=Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
    Source=Windows
    StackTrace:
         at Windows.UI.Xaml.Controls.Frame.Navigate(Type sourcePageType, Object parameter)
         at Cirrious.MvvmCross.WindowsUWP.Views.MvxWindowsViewPresenter.Show(MvxViewModelRequest request)
         at Cirrious.MvvmCross.WindowsUWP.Views.MvxWindowsMainThreadDispatcher.RequestMainThreadAction(Action action)
         at Cirrious.MvvmCross.ViewModels.MvxNavigatingObject.ShowViewModel[TViewModel](IMvxBundle parameterBundle, IMvxBundle presentationBundle, MvxRequestedBy requestedBy)
         at Cirrious.MvvmCross.ViewModels.MvxAppStart`1.Start(Object hint)
         at Test.Uwp.App.OnLaunched(LaunchActivatedEventArgs e)
    InnerException: 
  </code></pre>
  
  <p>I am using Windows 10 RTM and Visual Studio 2015 RTM, no beta bits (except for MvvmCross).</p>
  
  <p>What am I doing wrong?</p>
  
  <p>I absolutely love MvvmCross and I'm beginning to port an existing Windows 8.1 / Windows Phone 8.1 solution to Uwp - just doing some exploratory research on using the latest MvvmCross bits with Uwp.</p>
  
  <p>Thanks for any help!
  @ehuna</p>