Cannot install Xamarin.Android.Support.v4 - android

I am trying to install this particular package into my program and get the following error:
Error Could not install package 'Xamarin.Android.Support.Compat
24.2.1'. 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.
What exactly is my project suppost to target and how do I make this change? I already installed android 7, however I cannot even target that for some strange reason. Not even if I make a new project I can't target that.

This package requires MonoAndroid70 to be installed. Thus you need to ensure your TargetFrameworkVersion is set to a minimum of Android 7.0. You will need to install API 24(7.0) and change the version.
https://developer.xamarin.com/guides/android/application_fundamentals/understanding_android_api_levels/#framework
For those interested in how you would find this, you can download the .nupkg from NuGet:
https://www.nuget.org/api/v2/package/Xamarin.Android.Support.v4/24.2.1
You can then extract the .nupkg and view the lib folder which will show you what the library supports.

I recommend below steps
1- download a previous version (
<package id="Xamarin.Android.Support.v4" version="23.1.1.1" targetFramework="monoandroid60" />
)
2- delete the following local folder "..\AppData\Local\Xamarin"
3- Build the droid project (it will take some times)
Finally, no more issues with these xamarin support packages.
Cheers UP!

The solution:
Try to update your xamarin visual Studio after you will install it and you will get monoandroid v7
update your android sdk Api 24 or api 25
I think it will help you.

I removed from the Android SDK all API dependencies 23, ie Android 6.0 and installed from 7.0 and 7.1 (AP 24 and 25).
Clean and Rebuild the project.
Done that, it worked correctly.
Hope this helps.

Related

com.google.gms.location does not exist

I am trying to add a map on the Xamarin.Android application. So far, I have added only map, I did not add any location listener. However, I keep getting the following error
package,com.google.gms.location does not exist
I wonder what I am missing or doing wrong?
Here is the dll's added into the references from the nuget
Make sure all packages are of the same version (27.0.0)
Make sure Xamarin.Build.Download is installed (it downloads the required .jar files etc.)
Clean & Rebuild the android Project
Try entering Update-Package -Reinstall Xamarin.GooglePlayServices.Locationinto the package manager console
Clean & Rebuild the android Project
Try a higher version number of the package (newer ones are stable too)
If you want to use GooglePlayService. The test device/emulator of your app needs to include Google API. If you are using an emulator you can follow the steps below:
Download Google API System Image for your android API Level through Tools->Android->Android SDK Manager(ex for API Level 25 ):
Create a new Google API Emulator through Tools->Android->Android Emulator Manager->Create:
Clean your project and rebuild it, run your project in this emulator.

IntelliJ Idea 12, Incompatibile SDK Tools package

I am writing my first android application and after constructing two basic views in IntelliJ 11 I was advised to switch to 12 for the visual Designer tool.
I have loaded the existing project into IntelliJ 12 and when I try to run it on an AVD I get the following error
"android-validator: [PanPlan] Incompatible version of Android SDK Tools package. Min version is 19. Please, update it though SDK manager"
When I open the SDK manager however it seems I have the latest Tools package:
The project structure
As per #ekudel's suggestion, attaching contents of /android-sdk-macosx/tools/source.properties
Pkg.UserSrc=false
Pkg.Revision=22.0.5
Platform.MinPlatformToolsRev=18
The workaround I found after days of struggling is far from perfect and I'm willing to accept a different answer should one appear. Hopefully anyone struggling with the same problem will find this useful.
I found no way of importing the old project to work in IntelliJ Idea 12
I had to disable the mac warning for downloaded applications for the android-sdk-macosx folder. (Using this guide.)
I had to manually copy/paste code and resources from the old project.
This only worked if I selected the 4.2.2 as the platform, selecting 4.0.3 led to the same
""android-validator: [PanPlan] Incompatible version of Android SDK Tools package. Min version is 19. Please, update it though SDK manager" error.

I am geting an error while building android project?

gen folder is missing is the issue.The build patch failed .I have tried all solutions posted previously on this and no luck.
EDIT
To make it clear here is my original post
https://salesforce.stackexchange.com/questions/9460/encountering-issues-while-developing-android-hybrid-mobile-app
I am using salesforce SDK but when i am creating hello world app using native its working fine
Even if you delete the gen folder, it'll regenerate it after you compile your program.But if it is not then try creating a new project and try it again .If not , try a fresh installation of the API.
Update
Hmm, everyone in both posts is telling you to download the "SDK Platform" for "Android 2.2 (API 8)". I really, really recommend trying this. It is apparently required by the library you added to your project...
I have 4.2 and 4.1 .Is that not enough?
No, you must have the older platforms that you are building against.
Simply download it and open Project > Properties, click on Android, then select Android 2.2. After all this clean your project and save it.
Original Answer
The screenshot doesn't give us much detail, but:
Unable to Resolve target 'android-8'
Tells me that you probably don't have the SDK Platform for API 8, simply download this through the SDK Manager. Or you can change any references in your manifest and the rest of your code to use an API that you already have.
I think it is because when
you import a project, build
target is not set in the
project properties which
then default to the value
used in manifest file. and make sure you have API 8.
The solution is to enable
build target toward your
installed API level (but keep
the minimum api support as
specified in the manifest
file).

android Support library

When I want to create new android Project, everything is OK but after the last step (about activity) eclipse said it has problem and said:
this template depends on the android Support library, which is either not install, or the template depends on a more recent version than the one you have installed.
link
required version 8
installed version: not installed
and If I use "upgrade/install" bottom, eclipse said :Android Compatibility JAR not found.
I found this solution on the net but I could not use it:
Steps:
Run your Android SDK Manager
Find Extras > support Library and delete that particular Library
Now Relaunch Android SDK MAnager
Download the Extras > support Library present
there is sth important: I am in Iran, because of the boycott, we couldn't download easily.
I use these tools:
Java.SE.Development.Kit.v7.0.Update.5.x86_p30download.com.exe
Eclipse:
Version: Juno Release
Build id: 20120614-1722
ADT-20.0.0
platform-tools_r13-windows.zip
android-2.3.3_r02-linux.zip
tools_r20-windows.zip
I think you are correct about the way to solve the problem - you need to download a package with SDK Manager.
I'd tried to upload my libraries, but not registered at any file-upload services. So I will recommend you to use some ananymizers or smth like Tor ( http://en.wikipedia.org/wiki/Tor ) and download all necessary libraries for development.
Good luck.
try update your ADT plugins (currently 20.0.3), go to Eclipse > Help > Check for Updates, not sure if this is the place in Linux
This happened to me too, but now solved by Right click on SDKManager.exe then run as administrator and download your required packages
according to : http://comments.gmane.org/gmane.comp.handhelds.android.devel/220558
I had a same problem so i used proxy.
in Eclipse go to :
windows-->preferences-->general-->network connections
And for SDK manager
In the Android SDK Manager go to :
Tools-->options-->enter your proxy
Now you can update your eclipse and sdk with no problem
I hope this work for you:)

Changing Android Project SDK level

I started writing my first Android app, and chose SDK 2.0.1, before I had an android phone.
I wantto test the app on a phone that is Android 1.6. The app itself uses pretty simple stuff, so I'm sure its 1.6 compatible, but I want to change the SDK level from Eclipse.
The "default.properties" file in my project tree and naively tried to change from Android 6, but it isn't changeable, but if I try to change it it tells me to change the build.properties of the project. I don't know what that means. I'm not used to eclipse and am still fumbling around it.
I went to the project properties and clicked on "Java Build Path", but from there I don't know how to add,remove or edit the libraries.
Basically, I'm asking how to downgrade my project from inside eclipse, so I can export it to a compatible phone.
You can actually keep the project's targetSDK at the same level, and just use a minSDK value.
What this means is that your application will target to build against a certain API, but it will let phones with lesser versions of Android than that API to also run the app. The catch is that you have to make sure you don't make any API calls that don't exist in the older versions of Android.
To change this, go to your AndroidManifest.xml and add the following inside of the xml node:
<uses-sdk android:minSdkVersion="3" />
This would set your minsdk to Android 1.5. Change it 4 for Android 1.6 and so on.
But if you really want to change the TargetSDK, right click on your project --> properties. Then click the Android tab on the left. Then check the box of the target API you want to build against.
Some more versioning info can be found here.
You can change your the Build Target for your project at any time: Right-click the project in the Package Explorer, select Properties, select Android and then check the desired Project Target.
PS : I'm on Eclipse Helios
http://developer.android.com/guide/developing/eclipse-adt.html

Categories

Resources