Visual Studio 2015 Xamarin deploy fail without any error message

后端 未结 20 616
隐瞒了意图╮
隐瞒了意图╮ 2020-12-18 17:54

I just installed VS 2015, the installation was finish (after some fail time caused by the slow network, I run setup again).

I create a project as Adroid > A

相关标签:
20条回答
  • 2020-12-18 18:35

    This worked for me:

    • Making sure that Define DEBUG constant is checked.

    • Using Log.Info("yourTag-AnyString", "Error before/after ");

              protected override void OnCreate(Bundle bundle)
              {
                  base.OnCreate(bundle);
      
                  // Set our view from the "main" layout resource
                  Log.Info(tag, "Error before Layout");
                  SetContentView(Resource.Layout.Main);
      
                  // Get our button from the layout resource,
                  // and attach an event to it
                  //Button button = FindViewById<Button>(Resource.Id.MyButton);
      
                  //button.Click += delegate { button.Text = string.Format("{0} clicks!", count++); };
                  Log.Info(tag, "Error before variables");
                  userName = FindViewById<EditText>(Resource.Id.editTextUsername);
                  password = FindViewById<EditText>(Resource.Id.editTextPassword);
                  btnInsert = FindViewById<Button>(Resource.Id.btnInsert);
                  Log.Info(tag, "Error after variables");
                  btnInsert.Click += BtnInsert_Click;
              }
      
    • changing emulators or exporting the signed .apk instead

    • For android apps, using android device logging

    0 讨论(0)
  • 2020-12-18 18:38

    If the emulator does not even lauch, maybe deploy is skipped. You cas see this in the output console. If so, you may have to activate the deploy by checking it in the solution's (not project) parameters.

    If the emulator launches but the deploy won't end after minutes, with no error, try the steps described here : https://stackoverflow.com/a/32564067/7505268 That solved it for me.

    0 讨论(0)
  • 2020-12-18 18:39

    According to Magnus Grindal Bakken's comment, I found the solution.

    1) The installation must have an internet connection to be completed. Any interruption may cause components to be excluded.

    2) You need android emulator. Installing the Android SDK and Visual Studio 2015, is not sufficient, You either need the Microsoft emulator, the android one or another third party emulator (like Genymotion). You also need to ensure that the Xamarin plugins for Visual Studio are installed.

    Xamarin for Visual Studio can be downloaded here. Once it is installed Visual Studio will be able to create and run Xamarin projects. Xamarin for VS includes the Xamarin Player for emulation. I think it's even better than Genymotion.

    0 讨论(0)
  • 2020-12-18 18:41

    I had the same problem with my XF App, it didn't deploy and just one message saying Deployment Failed, internal error....

    I solved it. Working on Mac with Xamarin Studio, make sure that the ABI of your simulator is supported by your app.

    Xamarin Studio Android project Options

    0 讨论(0)
  • 2020-12-18 18:41

    Well there can be many reasons,one of them could be that from the Build section in your toolbar,if you check the configuration manager there will be project names that are available in your current solution all you have to check is if the deploy checkbox is checked or not.If not kindly check it and things will work just fine

    0 讨论(0)
  • 2020-12-18 18:42

    Start emulator via AVD manger ... [start] button (as user m93a suggested).

    And next option contains check option "wipe user data". Check it !

    It helps me solve this problem. Then deploy or debug the application and all process will works as expected.

    0 讨论(0)
提交回复
热议问题