Xamarin.Android CrossPlatform Application not Run - xamarin

I have Installed Xamarin with Visual Studio. Xamarin Forms Application Run well on Ios and Windows Platform but it does not run on Android Phone.
I am getting Error
Severity Code Description Project File Line Suppression StateError
Please install package: 'Xamarin.Android.Support.v7.MediaRouter' available in SDK installer. Java library file C:\Users\Admin\AppData\Local\Xamarin\Android.Support.v7.MediaRouter\23.0.1.3\embedded\classes.jar doesn't exist. App4.Droid
Please Help me to solve this problem.Thanks in advance.

it is a packaging error do you have to install Xamarin.Android.Support.v7 this package to particulate project it it is not working then try next option like,
Download .jar file for particular API Level 23.0.1.3 and Extract it on C:\Users\Admin\AppData\Local\Xamarin\Android.Support.v7.MediaRouter\23.0.1.3\embedded\

Related

Xamarin: Try to run the Project. I'm new bee for xamarin and want to run my xamarin ios project

I want to run the xamarin ios project and maybe its native code for ios xamarin.
I install visual studio for mac and open the project, then add missing packages.
But in One package Zxing.Mobile I get the error (I can't find relative package) So I comment related code and try to run the project. So I get the few errors and here I attached that snap
So please help me I'm iOS native developer and want to run this xamarin project.
This error generally occurs when a dependency of your nuget package is having an issue and can't be linked. You can try installing the dependency nuget package manually and that should resolve it.

Appcelerator | 'Android Distribution' Android SDK version 4.1.2 not found

I have pulled an Appcelerator project from our developer group and unable to publish or run the project on a local Android device.
When trying to publish the below error screen immediately pops up.
Android SDK version 4.1.2 not found.
I have checked both in the Appcelerator platform settings and Android Studio config and have the SDK installed.The install SDK screen in Appcelerator Tried uninstalling/reinstalling Appcli and the SDK to no avail.
After a few days of searching all the appecelerator files in my project. I finally found the fix for my problem (for anyone googling this).
There's a hidden file in the root of the Appcli project called .settings
Inside of settings there's a package called com.appcelerator.titanium.android.core.prefs
There is an android/sdk_version=4.1.2 that was causing all my issues. Hope that helps someone.
Most likely, your issue seems to be with unsupported Android SDK version as per Ti SDK you are using.
So before doing anything, try to grab what this page says to know all about software compatibilities: Titanium Comptability Matrix
It says that minimum Android version as of latest Ti SDK 6.x.x is API 16.
Now, follow these steps carefully to get a fresh start on your system.
First of all, download Android latest SDK from here: Android SDK
Unzip it & put it in at some simple path like in /Users/username/android-sdk
Download Appcelerator Studio (AS) & install it. It will download all pre-requisites like Java, Python
Open Appcelerator Studio & go to Preferences->Studio->Platforms->Android. Select the path of android sdk you unzipped in step 2.
After all these steps, you can open Android SDK Manager (see screenshot where it is) & install necessary SDK, Tools, etc.
Note: I do not suggest to download SDKs via AS as I have faced path issues in beginning.
Even if these steps do not help you, then provide us the log output after running this command on terminal: appc info
If terminal says this command is not found, then you need to go through the AS installation properly.
I had the same issue. Simply deleting all " Android Play Store Distribution" configurations solved my problem.

Xamarin Forms Push Notification: Android.Support.v7.MediaRouter Error

I am trying to add push Notifications to my application and I have added xamarin.google.playservices.Gcm package into my project and now I am getting the following error.
Error XA5207: Please install package: 'Xamarin.Android.Support.v7.MediaRouter' available in SDK installer. Java library file /Users/xyz/.local/share/Xamarin/Android.Support.v7.MediaRouter/23.3.0.0/embedded/libs/internal_impl-23.3.0.jar doesn't exist. (XA5207) (NotificationExamplenew.Droid)
1) Check MediaRouter NuGet package was added to you project and project References.
2) Check Android SDK manager for latest update on our target SDK
And latest Support Library
Make sure , u don't add the these package manually , some time xamarin forms are not compatible with newest releases of android pkgs,
simply remove all the package , and add Xamarin forms from nuget ,this will automatically download all the required dependency
also make sure to install required packages , from tool-> android sdks manager -> select relevant listiings (extras in last).
I have succesfully implemented GCM based push notification let me know if u get stuck somewhere
If you already have Android Support Library installed and still you get this error then the following solution might work.
I deleted the folder 23.3.0.0 from the folder C:\Users(UserName)\AppData\Local\Xamarin\Android.Support.v7.MediaRouter and rebuilt the project again to fix it.
Basically, Xamarin picks the right version from Android SDK and extracts files in the above mentioned folder.

Xamarin Error: No Android Platforms installed

is anybody familiar with the errors showing in attached screenshot. can anyone help to resolve?There are two errors when i tried to build sample xamarin android app.
Click here for screenshot
Open SDK manager and install API levels on your machine. Search for SDK manager in your programs. And download the Android SDK platform-tools, which is located in Tools folder
For more information take look here
It appears that Visual Studio/Xamarin is not finding your Android SDK installation.
Xamarin.Android Manual Installation
https://developer.xamarin.com/guides/android/getting_started/installation/windows/manual_installation/

Attempting to add an MQTT library from NuGet into Xamarin project

I saw that Xamarin was now free and decided to try writing a mobile app using it instead of what another technology I was playing with. After some various hiccups, I was able to get the new Xamarin Android project to build, deploy and run on the simulator. I then decided to try out MQTT connectivity from it before I went any further. No matter which MQTT library I to install from NuGet, for example the System.Net.Mqtt one from Xamarin, I get the following error:
"Could not install package 'System.Net.Mqtt 0.3.12-pre'. You are trying to install this package into a project that targets 'MonoAndroid,Version=v6.0', but the package does not contain any assembly references or content files that are compatible with that framework. For more information, contact the package author."
I tried several others with no success. It does the same for the ios and Android projects. I did try changing the Android SDK version to use for compiling, but still had the same result. I also don't understand why it says MonoAndroid since I thought all the Mono references were changed to Xamarin? I'm using Visual Studio 15 with Update 2. I tried the stable Xamarin version and also tried the latest alpha. I'm not sure what else to try, I'd really to give Xamarin a try for this project. I did some searching and couldn't find anything that appeared to help with this issue.
Thanks in advance for any help.
Use the Package Manager Console. Then, either:
Install the latest version of MQTT library.
Or install first its dependency, RX-Main and then MQTT.
If you still get an error, please share with us the Log that is shown in the PM Console.

Resources