I decided that I want to work on my Xamarin apps in Rider, IDE from JetBrains. I tried to do that yesterday and the problem was, I can't for some reason deploy my app on physical iOS device (iPad 4). In Visual Studio 19 for Mac it works fine, so my provisioning is fine.
When I try to run app with iOS default config, it offers me various deployment targets, all of which are simulators. But if I go to edit the configuration, I can select connected device and then select my iPad. Though, when I go to run the app again, I am once more greeted with list of simulators.
Please, help me figure out what the issue is, brief googling did not help.
I fixed it by switching from Debug configuration to Debug|Iphone configuration, then it showed my ipad as deployment target. Hope it helps someone
Related
I am trying to deploy my Xamarin.Android application from visual studio to my smartphone which is Huawei P10. During compilation a popup shows up:
After you close the popup an error shows up:
Severity Code Description Project File Line Suppression State
Error XA0136: The 'run-as' command failed with 'run-as: package has corrupt installation: com.companyname.app1'.
The currently installation of the package in corrupt. Please manually uninstall the
package from all the users on device and try again. If that does not work you can disable Fast Deployment.
Fast Deployment can be disabled in the Visual Studio project property pages or edit the project file in a text editor and set the 'EmbedAssembliesIntoApk' MSBuild property to 'true'.
Tools and Devices used:
Visual Studio 2019 version 16.10.1
Xamarin Android
Deploy to Huawei P10 Android 9.0 API 28
Any suggestions pls on what is the problem.
Thanks
UPDATE: If you disable Fast Deployment works fine
According to Xamarin, you have to activate the developer mode for this. In addition, debugging via USB must be approved. You can find the exact statement here on GitHub. If you don't know how to activate the mode, you can find instructions here.
Alternatively, if all these steps did not work you can disable 'Fast development'. Either do this in your project or via Visual Studio.
Fast deployment is known to fail on devices which block run-as, which often includes devices older than Android 5.0. Fast deployment also fails for system applications (android:sharedUserId="android.uid.system") since run-as is also blocked for system applications.
If these solutions work let me know!
I also got this issue when trying to run the app in emulator. But I fixed it by changing to new android emulator
I am trying to do physical testing for an iOS app using Xamarin Forms following this tutorial: https://learn.microsoft.com/en-us/xamarin/xamarin-forms/deploy-test/hot-restart, but I am running into a problem when trying to debug to an iPhone or iPad. There have been no issues doing physical testing on Android through usb or simulation testing through MacInCloud, but I run into this error when deploying to iOS through usb for testing:
"Xamarin.iOS does not support running or debugging the previous built version of your project. Please ensure your solution builds before running or debugging it."
My Apple Developer Account is successfully linked to Visual Studio and I have iTunes installed, so I don't know what the issue could be relating to. I have tried all the common fixes, such as cleaning and rebuilding the file, restarting visual studio, and trying multiple devices.
I appreciate any help I can get.
I started a project on Unity and I would like to test it on an Android device, but I am unable to do so. I researched every tutorial out there and couldn't find a solution that worked for me. Note: I have been using Android Studio and I am able to launch apps both through an emulator and a USB phone.
I am pretty sure I correctly chose all the settings inside of Unity
(followed every single tutorial I could find).
Turned on developer mode on phone and tried multiple setting
variations that I could find on the web.
Made sure all the drivers are installed correctly (wouldn't be able
to do stuff through Android Studio if I haven't).
Uninstalled Unity and Unity Remote 5 multiple times.
JDK and NDK seem to be working fine. Tried turning adb server on and
off multiple times. Also I can see my device with the 'adb devices'
command.
I had some issues with MalwareBytes when installing Unity. I did try
granting permissions to every Unity folder I could find, but I think
MalwareBytes could be the culprit.
Has anyone encountered a similar issue? Is there another thing I could try? Any help is apreciated.
EDIT: I switched my VPN to a VPN that allows open source software and I also uninstalled Malwarebytes and replaced it with Avira. Did not fix the issue.
I did not run in exact same issue, but working with Unity remote might be a little tricky.
It may require to launch Unity remote first before launching Unity itself. And I hope did not forget to ProjectSettings -> Editor -> Any Android Device option to be set. I'm talking about Window OS.
I had the same issue today. I also did everything was mentioned in tutorials and nothing helped.
Then I noticed that when I press 'Play' there's a message in the console "Set-up Android SDK path to make Android remote work in Unity". After I went to 'Edit'->'Preferencies' I unchecked the 'Android SDK Tools Installed with Unity(recommended)', then closed Unity, opened it again and checked the box again.
It worked for me, I hope it will help you too :)
When you connect your phone to your PC, you may chose the file transfer option in your Android device, but charge mode worked for me, this is what I did:
1-Make sure that the "Any Android Device" option in Project Settings/Editor, is enabled and close unity.
2-Open the Unity remote app in the phone and connect it to the PC, in charge only mode.
3-Open Unity and run the game
This method worked for me, I hope it works for you too.
i started recently working on a app for mobile devices with xamarin forms. To work on the GUI fluently i tried this:
Live Reload Preview
It worked with the Visual Studio Android Emulator. But i want to work with google's emulator becaus of the more recent updates. I get in VS the message, that LiveReload is enabled but not listening. So i tried a view things with the "Hostname" and "Port" field within the settings of live reload in VS. If i use the command "adb devices" i can see the emulator and it's port (5554 in my case).
Should Hostname stay at localhost? Or did i miss something? The project worked fine with VS Android Emulator and the Live Reload extension. So i can at least exclude a mistake in my code.
Would be great if there's someone who could help :)
Thanks a lot!!
I can usually find resolutions to my problems here, but no one seems to have experienced the problem I'm having.
I'm using VS2017, building a UWP app for Win10 Anniversary edition. The app deploys fine to the Local Machine and the emulator. However, when I try to start debugging on the phone (MS Lumia 950), the Deploy process finishes successfully almost instantly. Then I get the "Project needs to be deployed before it can be started..." message. I'm not seeing any error messages during deployment, just the one after deployment apparently succeeds. If I try to deploy from the Build menu, I get the same rapid deployment.
The phone and PC both are updated with the Creators update. I have rebooted the pc and the phone. I have checked the 'Deploy' option in Config Manager. The phone is unlocked when I deploy. If I unplug the USB cable, I get the expected "Bootstrapping failed. Device cannot be found." message. I don't have another USB-C cable to try, but I can see and explore the phone from File Explorer in Win10. I used "WinAppDeployCmd List -ip 127.0.0.1" to make sure the app really isn't on the phone.
I've developed some other UWP apps in VS2015, this is my first go with 2017. Sorry if I was overly verbose, I want to provide as much detail as I can. I don't know what to try next.
Thanks for any insight.
Don