我想填充谷歌地圖與用戶附近的地方,如酒店,餐廳等。 不幸的是我無法找到一個支持Xamarin機器人和地方API在xamarin android 任何建議如何實現這一目標?填充地圖附近的地方在Xamarin安卓使用地方API
回答
您正在尋找Xamarin.GooglePlayServices.Places
的NuGet:
<package id="Xamarin.GooglePlayServices.Places" version="32.940.0-beta3" targetFramework="monoandroid70" />
一旦添加到您的Xamarin.Android
項目,你可以在廣場的API添加到您的GoogleApiClient
:
mGoogleApiClient = new GoogleApiClient
.Builder(this)
.AddApi(PlacesClass.GEO_DATA_API)
.AddApi(PlacesClass.PLACE_DETECTION_API)
.EnableAutoManage(this, this)
.Build();
的地方API是在Android.Gms.Location.Places
命名空間。
似乎是一個解決方案,我是新的Xamarin Android可以告訴我如何使用這個。使用上面的代碼 .EnableAutoManage(this,this)給出的紅線錯誤表示無法從App4轉換爲Android .Support,V4.AppFragment Activity,並且無法從App4轉換爲System.Android
https://developers.google.com/places/android-api/start – SushiHangover
升級Xamarin.GooglePlayServices包後需要添加nuget包Xamarin.GooglePlayServices。 PlacesClass類的地方。 – mvandillen
- 1. 顯示在谷歌地圖搜索附近的地方安卓
- 2. 附近的地方xamarin形式IOS
- 3. 谷歌地圖附近的地方
- 4. bing地圖,尋找附近的地方
- 5. 安卓谷歌地圖填充圈
- 6. 安卓地圖方向
- 7. 谷歌附近的地方api顯示的地方類型和地方計數
- 8. 附近地方的Foursquare API iPhone
- 9. Foursquare iPhone API附近的地方
- 10. 方法來填充地圖
- 11. 用戶位置與谷歌地圖API地方自動填充
- 12. 如何檢索使用谷歌地方api附近的地方的照片?
- 13. Foursquare附近的地方
- 14. 查找附近的地方
- 15. iOS6 MapKit - 附近的地方
- 16. 附近的地方清單
- 17. 安卓在地圖上的方向
- 18. nullpointerexception當從谷歌地點api請求xml附近的地方
- 19. 如何在角谷歌地圖的地方附近隱藏?
- 20. 查看附近的地圖谷歌地圖在流星的地方
- 21. 谷歌的地方自動填充API安卓界限不工作
- 22. 谷歌地圖的方向和地區附近的路線
- 23. 如何獲得從附近的谷歌地圖的地方
- 24. 使用Google Places api查找附近的地方
- 25. 獲取距離過濾附近的地方使用谷歌地點api
- 26. 谷歌地圖找到當前位置和附近的地方
- 27. 谷歌地圖安卓方向
- 28. 安卓谷歌地圖步行方向
- 29. 使用GregorianCalendar填充地圖
- 30. 谷歌地圖地方api
使用場所的網絡API:http://stackoverflow.com/questions/29087675/requests-poi-from-a-location-using-xamarin-android –
你會使用代碼在那裏的答案,並用與在這裏答案的網址:http://stackoverflow.com/questions/30161395/im-trying-to-search-nearby-places-such-as-banks-restaurants-atms-inside-the-d –