2013-10-24 39 views
0

我一直在努力實現谷歌在https://github.com/xamarin/monodroid-samples/tree/master/MapsAndLocationDemo_v2播放使用步驟服務和https://github.com/xamarin/monodroid-samples/tree/master/GooglePlayServices發揮使用Android SDK中17項服務如何實現谷歌在xamarin

android update project -p "path to project" -t 4工作

螞蟻調試工作,更新project.properties,添加Api鍵

然而,在Mac上建立Xamarin工作室4.0.3得到this.using Xamarin安卓4.6。什麼包丟失。任何建議讚賞。我引用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) 

回答

0

我建議你使用谷歌從http://components.xamarin.com/播放服務。

步驟:

  1. 檢查你的谷歌遊戲服務API在Android SDK中經理。如果它不是rev​​。 12,更新它。如果這不可能,那麼檢查您的修訂版,並從Xamarin中找到合適的組件。他們支持rev。 9,rev。 10,和rev。 12.如果您想支持較舊的設備,請下載Froyo版本。 enter image description here

  2. 如果您更新到rev,請下載此組件。 12:http://components.xamarin.com/view/googleplayservices12/

  3. 解壓縮它,並在您的項目中引用下載的DLL。
  4. 使用方法如下:http://components.xamarin.com/gettingstarted/googleplayservices12
+0

注意,如果您需要在項目中添加一個組件,則需要在Xamarin獨立版本。 –