如何在 xamarin 上使用 android sdk 17 实现 google play 服务 [英] How to implement google play services using android sdk 17 on xamarin
问题描述
我一直在尝试使用
I have been trying to implement Google Play services using the steps in https://github.com/xamarin/monodroid-samples/tree/master/MapsAndLocationDemo_v2 and https://github.com/xamarin/monodroid-samples/tree/master/GooglePlayServices
android update project -p "path to project" -t 4
worked
ant debug works, updated project.properties, add Api key
However on build in Xamarin studio 4.0.3 on Mac get this.using Xamarin android 4.6. what package is missing. any advice appreciated. am referencing Mono.android,support.v4
/Users/TheCall/MapView/Components/googleplayservices-9.0/samples/GooglePlayServicesApp/GooglePlayServicesApp/obj/Debug/android/src/mono/com/google/android/gms/appstate/OnSignOutCompleteListenerImplementor.java(34,34):
Error: package com.google.android.gms.appstate does not exist
com.google.android.gms.appstate.OnSignOutCompleteListener (GooglePlayServicesApp)
I suggest that you should use Google Play Services from http://components.xamarin.com/.
Steps:
Check your Google Play Services API in Android SDK Manager. If it's not rev. 12, update it. If thats not possible then check your revision, and find the appropirate component from Xamarin. They support rev. 9, rev. 10, and rev. 12. If you want to support older devices, download the Froyo version.
Download this component if you are updated to rev. 12: http://components.xamarin.com/view/googleplayservices12/
- Unzip it, and reference the downloaded DLL in your project.
- Use it like this: http://components.xamarin.com/gettingstarted/googleplayservices12
这篇关于如何在 xamarin 上使用 android sdk 17 实现 google play 服务的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!