Bug 60929 - Android Xamarin Live Player - Dictionary Object of type 'System.Int32' cannot be converted to type 'NInterpret.InterpretedValueType'
Summary: Android Xamarin Live Player - Dictionary Object of type 'System.Int32' cannot...
Status: RESOLVED FIXED
Alias: None
Product: Live Player
Classification: Xamarin
Component: Mobile App Android ()
Version: 1.2.X
Hardware: PC Mac OS
: --- normal
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2017-11-30 14:21 UTC by ladislav.kopecky
Modified: 2018-01-10 23:09 UTC (History)
1 user (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description ladislav.kopecky 2017-11-30 14:21:28 UTC
Hello,

during development App in Xamarin I have strength issue in Android Xamarin Live Player. App is not executed and show exception:
[LogEntry: Time=30.11.2017 13:18:04 +01:00, Level=Error, Title=Visualization Error, Message=Object of type 'System.Int32' cannot be converted to type 'NInterpret.InterpretedValueType'. (ArgumentException)]


Development environment:
- OSX 10.13.1
- Visual Studio Mac 7.2.2 (build 11)
- Project Xamarin.Forms
- iOS SDK 11.1
- Android SDK 7.0
- Android Xamarin Live Player 1.2.80

public partial class App : Application
{

  public enum PageTypes
  {
    Empty = 0,
    Favorite
  }

  static Dictionary<PageTypes, PageModel> PageModels { get; set; }

  public App()
  {
    // Setting the Navigation Pages
    PageModels = new Dictionary<PageTypes, PageModel>() // <- Here occure exception
    {
      { PageTypes.Favorite, new PageModel {
          TitleMenu = "MENU",
          IconSource = "icoMenu.png"
        }}
           }; 
         
      InitializeComponent();
     }

    …...
}
Comment 1 James Montemagno [MSFT] 2017-11-30 17:10:40 UTC
Yeah, i noticed this recently. If you replace the enum with an Int it will work just fine. I have reported and working on it.
Comment 2 James Montemagno [MSFT] 2018-01-10 23:09:41 UTC
Now available in 1.4.134