How to implement Android Place Picker

  Рет қаралды 100,204

Android Mine

Android Mine

8 жыл бұрын

Android place picker is an widget that contains Google map.User can drag the map and place a marker therein and then user can select details address from that location and set to anywhere else.

Пікірлер: 148
@artvandelayimports
@artvandelayimports 8 жыл бұрын
Thank you so much man. Really simple. Good video
@shafaquesattar
@shafaquesattar 8 жыл бұрын
wow!! Great guy..What an example. Bravo!!!!!!..Bravo!!!!
@peeamoselane9108
@peeamoselane9108 8 жыл бұрын
That's some great and creative stuff right there
@franklinwistian
@franklinwistian 7 жыл бұрын
Thank you! I was already giving up
@aleksandarstanoevski3096
@aleksandarstanoevski3096 6 жыл бұрын
Great explanation :)
@sayedmasihullah6922
@sayedmasihullah6922 6 жыл бұрын
Thank you
@CopyNinjaKH
@CopyNinjaKH 6 жыл бұрын
Can you get the coordinates? (longitude and latitude)
@themarkwebs
@themarkwebs 7 жыл бұрын
superb nice video.
@zarkasyimatiin4025
@zarkasyimatiin4025 7 жыл бұрын
waw thanks sir its really work on me
@snehamegha1447
@snehamegha1447 7 жыл бұрын
Is it possible to place a pin at current location in Place Picker by default? If Yes, then can you please let us know how to achieve that in android.
@eitanudis
@eitanudis 5 жыл бұрын
hi i know its been a while since the video was released, but when i click create credentials->api key, it automatically gives me a key without letting me choose package name or fingerprint. can someone help me?
@wan_darmawan7
@wan_darmawan7 7 жыл бұрын
I've applied your code. it worked but only a few moments, after that back again to the activity. please help me? thank you
@rroossyyiidd
@rroossyyiidd 7 жыл бұрын
Thank you.. :)
@bhavingoswami5370
@bhavingoswami5370 8 жыл бұрын
hey can we add custom places in placepicker? and show them?
@agueroalvaro
@agueroalvaro 7 жыл бұрын
Pero que pedazo de video :))
@jeffchong8440
@jeffchong8440 6 жыл бұрын
Hi sir, How do I create a filter to only show nearby restaurants?
@arjunvenugopal4763
@arjunvenugopal4763 4 жыл бұрын
Nice. Bro, u can use OBS for recording your desktop.
@sairamalavuru6925
@sairamalavuru6925 7 жыл бұрын
Thank you
@nurindraict
@nurindraict 7 жыл бұрын
can you show me the code of main_activity.xml ?
@mohsinfarookh6746
@mohsinfarookh6746 8 жыл бұрын
good tutorial
@simonebiliato3170
@simonebiliato3170 5 жыл бұрын
How to set the initial position?
@LChangeTheWorlDS
@LChangeTheWorlDS 7 жыл бұрын
Can I have your code? because I write down the code similar to this clip and I've got some bugs and I don't know why
@naveedakhtar63
@naveedakhtar63 6 жыл бұрын
nice job
@undanumundathium
@undanumundathium 8 жыл бұрын
Thanks
@parthbarot7502
@parthbarot7502 7 жыл бұрын
would you please provide your mainactivity.java code and all layout (xml file) code.
@vonzeusgallego1493
@vonzeusgallego1493 7 жыл бұрын
im trying to get the latlng of the location, but it gves me something like "latlng: (123213,12323)" not 12343,1234. can u please help me to just get the numbers not with "latlng" etc. please
@willsluder929
@willsluder929 7 жыл бұрын
I am having several issues with this code. First, I cannot manage to compile with support:design:23.2.1. I am on version 25, so tried support:design:25.0.0 and that didn't work either. I also cannot compile using the entire play-services:7.3.0 (I use 10.0.1). I get "Execution task failed for task ':app:transformClassesWithDexForDebug'". I looked into this a bit myself and this seems to be a problem for a lot of people. The leading solution is to selectively include specific packages from play-services. I compiled with auth, base, location, maps, and places (see this link for all the options developers.google.com/android/guides/setup). When I don't include design and use the play-services I named above, when I click the Get Places button nothing happens. The logs report that "Google Play Store is missing." and "Google Play Services not available due to error 9". This post, stackoverflow.com/questions/13346535/googleplayservices-not-available-due-to-error-9, reveals that this is because my GooglePlayServices is not authentic. How do I fix that?
@willsluder929
@willsluder929 7 жыл бұрын
stackoverflow.com/questions/40954931/implement-placepicker-in-android-studio
@brandkate9947
@brandkate9947 7 жыл бұрын
Hi, it it possible to also return a photo/icon or an image of the places using place picker?
@androidmine5559
@androidmine5559 7 жыл бұрын
Please open the place picker api from developer.google.com and check whether any up-gradation is made in their api...When I made this tutorial at that time very small info was there ..I left Android development 4 months ago to work on Java development ..best of luck
@brandkate9947
@brandkate9947 7 жыл бұрын
Thanks man, I'll definitely check it out.
@dipesh7512
@dipesh7512 7 жыл бұрын
yes you can change them to custom markers
@ktgoffice7068
@ktgoffice7068 3 жыл бұрын
For Me, it's not showing any location name or Lattitude & Longitude and also if we drop pin in somewhere it not showing the place name. Kindly help me to solve this? @AndroidMine
@abdulrazakhusin5515
@abdulrazakhusin5515 8 жыл бұрын
Hi I managed to create an app exactly as shown in this video. Although the place picker runs perfectly ie I can move the marker around and get the nearby location, it has problem to detect my current location (through AVD for now), unlike shown in this video where it seems like it can detect the author's location. Am I missing anything from this video?
@androidmine5559
@androidmine5559 8 жыл бұрын
+Abdul Razak Husin Are you using Google's own emulator ? If so then I would like to request you download the Genymotion and run on that ....I can give you support...
@abdulrazakhusin5515
@abdulrazakhusin5515 8 жыл бұрын
I managed to install and run genymotion with google play services correctly. Unfortunately , place picker is still unable to determine current location. As workaround i can key in the lat and long in the gps and get the correct location. Any idea how to make the place picker able to determine current location.
@sayedmasihullah6922
@sayedmasihullah6922 8 жыл бұрын
+Abdul Razak Husin activate the GPS button from Genymotion...then select a location from map then close that map and gps setting now open the Place Picker
@abdulrazakhusin5515
@abdulrazakhusin5515 8 жыл бұрын
I was hoping place picker able to detect current location thru wifi like we can do using laptop. Seems like it can't. Anyway can we filter the type of nearby places like ATM or gym etc?
@josephshrestha7263
@josephshrestha7263 8 жыл бұрын
+Abdul Razak Husin ....i have done exactly same as the video bt when i launch the aplication..on the click on my nearby business it wont display the detail on that
@conanhatore3279
@conanhatore3279 8 жыл бұрын
hi thanks for this tutorial but I have one question please. my application is working and it fine I can go to map and move around on it and search name of placeses in search box but I Can't select directly from the map ? if there was an solutions please let me know. thanks
@sayedmasihullah2375
@sayedmasihullah2375 7 жыл бұрын
Brother I am not getting your point.. what the actual thing you want to be implemented ?
@jesusmartinez5285
@jesusmartinez5285 7 жыл бұрын
I have the same problem, i can select places if I search directly from the search menu, but i cant select a place from Market, if i click on "Select Location" i can click on "Change Location" but i can't click on "Select". Someone can help me?
@sustar9351
@sustar9351 8 жыл бұрын
Hello :) In my code, in the mainactivity.java, Intentbuild and builder saw red . I can not run . Why do you think ? Thank you much.
@sayedmasihullah6922
@sayedmasihullah6922 8 жыл бұрын
+Su Star Please Surround with try catch block
@sustar9351
@sustar9351 8 жыл бұрын
Sir, Is it possible to share the code's GitHub or elsewhere . Do you have a blog address ? Thank you very much :)
@RishabhArora281294
@RishabhArora281294 8 жыл бұрын
The google place picker map keeps crashing/closing after few seconds. Any solution for that?
@androidmine5559
@androidmine5559 8 жыл бұрын
Yes friend ....Your google_place_api key is not correct ...Please get your proper SHA-1 fingerprint and package name from manifest file and then recreate the api key ...Hope it will run properly ....If not then go to console.developer.google.com and open the Google Place Api key and enable it from your console...It must work ....Where you are running in ?
@RishabhArora281294
@RishabhArora281294 8 жыл бұрын
Yes my SHA-1 fingerprint was the problem. It is working now! thank u so much!
@androidmine5559
@androidmine5559 8 жыл бұрын
Have you rated the video positive ?
@sustar9351
@sustar9351 8 жыл бұрын
Hello , how can I make the map appear in the border opened for the first time in a country I want ? Or on a smaller area .. Thank You So Much :)
@sayedmasihullah6922
@sayedmasihullah6922 8 жыл бұрын
+Su Star Please tell me the exact thing you wanna do
@sustar9351
@sustar9351 8 жыл бұрын
I want to darken a part of the map so I want to limit the map. Examples You can only search in Paris .You have no place in a map outside of Paris.
@androidmine5559
@androidmine5559 8 жыл бұрын
use LatLongBound method and set the 4 lat-long of the four sides of the paris
@emiliors1977
@emiliors1977 4 жыл бұрын
Hi, I don't have any errors in the java file but when I launch the activity in the phone, the place picker is opened and close, why?
@ayanbhattacharjee2745
@ayanbhattacharjee2745 4 жыл бұрын
same issue
@EngTarek831
@EngTarek831 7 жыл бұрын
Is there any way to change the map type to Hybrid (Satellite) map ??
@androidmine5559
@androidmine5559 7 жыл бұрын
I have not checked it out ..If I find surely I will reply you..Thank you ..Please like the tutorial
@EngTarek831
@EngTarek831 7 жыл бұрын
Android Mine already liked it...thanks for your response
@JoseSilva-yi7qj
@JoseSilva-yi7qj 7 жыл бұрын
Someone could give me some tips on how to develop a android App to find places like a school. It would work something like this: 1. When I type the name of the city, 2. a summary of the information of the schools that has in the city appears. 3. Then , when I click on a school 4. A new screen with more complete information is created.
@androiddeveloper6040
@androiddeveloper6040 3 жыл бұрын
No virtual method zzbo(Landroid/content/Context;)V in class Lcom/google/android/gms/common/GoogleApiAvailability; or its super classes (declaration of 'com.google.android.gms.common.GoogleApiAvailability' appears in /data/app/com.example.eventfinder-CvUdaLEuo8R9shbZtYB4Ig==/base.apk) this error is found in logcat plz tell me solution of this
@maazhasnain
@maazhasnain 7 жыл бұрын
Place place =PlacePicker.getPlace(data,this); iam having an error" cannot resolve method getplace" in the parameters
@androidmine5559
@androidmine5559 7 жыл бұрын
what is ur data?
@jhaygonzaga5391
@jhaygonzaga5391 7 жыл бұрын
sir an warning pop up "the on activityresult was never used" why?
@androidmine5559
@androidmine5559 7 жыл бұрын
@jhay Gonzaga Can you send me the screenshot of the problem here ? sayed.masih19andy@gmail.com
@jhaygonzaga5391
@jhaygonzaga5391 7 жыл бұрын
i have already solved it sir thanks but i cant select the custom location with no address only LatLong, do i really need to select the nearby place????
@sayedmasihullah6922
@sayedmasihullah6922 7 жыл бұрын
Yes you must select places ..but there is a option for latlng also
@avikenz3334
@avikenz3334 7 жыл бұрын
hello Gonzaga ! how did you solve it ? i Have the same problem...
@danialzafar8574
@danialzafar8574 7 жыл бұрын
When clicking on Get Place text. The App stops working. Did everything same as you did. Please guide me.
@sayedmasihullah6922
@sayedmasihullah6922 7 жыл бұрын
Yes bro everything same and correct .Please check or create your google place api for Android
@jhaygonzaga5391
@jhaygonzaga5391 7 жыл бұрын
try changing intent = builder.build(getApplicationContext); to intent = builder.build("name of your activty or java class");
@sayedmasihullah6922
@sayedmasihullah6922 7 жыл бұрын
Both should work. .please check with your Javafile.class
@roberts.s
@roberts.s 4 жыл бұрын
Hi bro, can you help me ? my place picker always close in a second after i click textView. i don't have idea bout this, can anyone help me ?
@roberts.s
@roberts.s 4 жыл бұрын
I've solved my problem. This method is deprecated, now google have new API call Autocomplete Place. This is the documentation: developers.google.com/places/android-sdk/autocomplete#add_an_autocomplete_widget But, you must do activated billing account in console.developers.google.com Google give $300 for first time, you can use it for free until this credit off or 12 months of using API.
@user-ew2xq8rj4l
@user-ew2xq8rj4l 4 жыл бұрын
Can you share your code please! because I have the same problem
@mubashersaeed
@mubashersaeed 4 жыл бұрын
hi sir, I am using same code but map open and then close immediately. kindly give me solution. thanks
@amrashraf170
@amrashraf170 4 жыл бұрын
I have the same problem any solutions ??
@jesusmartinez5285
@jesusmartinez5285 7 жыл бұрын
Can you upload the code? I have problems with the marker. Thanks.
@androidmine5559
@androidmine5559 7 жыл бұрын
I don't know where I have kept that code ..Please tell me one by one step ..I can help you until it runs ..
@Nikhil-fm4ii
@Nikhil-fm4ii 7 жыл бұрын
can you please tell me the meaning of what is PlacePicker.IntentBuilder
@androidmine5559
@androidmine5559 7 жыл бұрын
IntentBuilder is for building an object to go to the place picker with place picker request ..
@taimoorshaukat6206
@taimoorshaukat6206 8 жыл бұрын
any code link of this video
@FallenMorphine
@FallenMorphine 8 жыл бұрын
Hello, great video and thanks! Ive got one question. I am creating my own app and wanted to add this function: When you click on the "Google Maps" Button, then it opens "google maps" and shows your current position AND it should ONLY show >> bars, discos, pubs .< I used this tutorial for the "current position": www.androidtutorialpoint.com/intermediate/android-map-app-showing-current-location-android/ You can find the .java code here: www.androidtutorialpoint.com/wp-content/uploads/2016/04/MapsActivity.txt Anyone here who could help me?
@josselynegutierrez3167
@josselynegutierrez3167 4 жыл бұрын
did you do it? I'm stuck with something like that ...
@meyhartbangkitsitorus5235
@meyhartbangkitsitorus5235 7 жыл бұрын
There is bug for Place Picker in these device : LG G4 (p1) Xperia Z5 (E6653) Mi Note (virgo) Xperia Z3+ (E6553) Xperia Z4 Tablet (SGP771) MI 3W (cancro) Xperia Z5 Compact (E5823) Xperia Z5 (E6603) Xiaomi Redmi Note 4 So if you run this code in that device maybe it will get force close with no error argument... See this forum issuetracker.google.com/issues/35827842
@lokendrasingh-yi5dt
@lokendrasingh-yi5dt Жыл бұрын
Jai Shree ram jai hind
@bhavingoswami5370
@bhavingoswami5370 8 жыл бұрын
" java.lang.ClassCastException: android.app.Application cannot be cast to android.app.Activity" help got this error..
@androidmine5559
@androidmine5559 8 жыл бұрын
Can you please show me your ManinActivity file over here ?
@bhavingoswami5370
@bhavingoswami5370 8 жыл бұрын
Solved was just an import error :)
@champ666ZA
@champ666ZA 7 жыл бұрын
how did you solve this?
@bhavingoswami5370
@bhavingoswami5370 7 жыл бұрын
@evan can u please comment you logcat error?
@bhavingoswami5370
@bhavingoswami5370 7 жыл бұрын
please show me your main activity ....
@JootheOwl
@JootheOwl 7 жыл бұрын
how to auto show place without button get place?
@androidmine5559
@androidmine5559 7 жыл бұрын
Look there is a method is executed on click of get place text view .so if you want to show automaticly you can just run method inside the oncreate method of main activity ...Thats all
@JootheOwl
@JootheOwl 7 жыл бұрын
Android Mine I've try method on the onCreate but the place does not appear automaticly but just show maps only
@androidmine5559
@androidmine5559 7 жыл бұрын
map is loading ? If so then obviously there places should be loaded ..if not then it is Google's api changed ...but I left Android 6 months back ....I have never worked on place picker after I posted the video ..thereafter they changed a lot
@JootheOwl
@JootheOwl 7 жыл бұрын
Android Mine No loading. After i run apk just display the usual maps that i made
@nikeshsangale1765
@nikeshsangale1765 4 жыл бұрын
please provide code for this video
@realworld629
@realworld629 7 жыл бұрын
i have used your code in fragment and when I'm trying to get the current place it is showing null ,plzz help me what can i do?
@androidmine5559
@androidmine5559 7 жыл бұрын
Go to your Google account console and activate /enable the Android place picker ...ITill if it does not work then create your api properly ..Hope I helped you
@realworld629
@realworld629 7 жыл бұрын
yaa i have made it enable but still after clicking on location not taking name of place ,it is showing "Get Place:Null"
@androidmine5559
@androidmine5559 7 жыл бұрын
I am also stuck in PayUBiz integration in Android ...Once I am done my job I will try to focus on your code ..
@realworld629
@realworld629 7 жыл бұрын
there is some improvement now showing nearBy locations also and i can select it but after selecting it showing nothing....don't know why!!!!
@androidmine5559
@androidmine5559 7 жыл бұрын
Check the onActivityResult method properly ...hope it will work at the end of the day
@dineshpatidar211
@dineshpatidar211 5 жыл бұрын
In my case Map open and close immediately..! Pls help me sir
@hunainhumail6385
@hunainhumail6385 5 жыл бұрын
This is because, the google has deprecated Place Picker and now you can check out Google docs to implement alternative for that..
@dineshpatidar211
@dineshpatidar211 5 жыл бұрын
@@hunainhumail6385 ok sir, thanks for reply.
@ashwiniramapure7783
@ashwiniramapure7783 7 жыл бұрын
can u plz share the code ?
@androidmine5559
@androidmine5559 7 жыл бұрын
hii have you implemented PlacePicker successfully ?
@s4-ali
@s4-ali 5 жыл бұрын
did he really say pholks at 00:00 ? ;p ;p
@ezazgori6352
@ezazgori6352 4 жыл бұрын
Yes man 😂😂
@franklinwistian
@franklinwistian 7 жыл бұрын
intent = builder.build(MainActivity.this); Place place = PlacePicker.getPlace(this, data); :)
@jhaygonzaga5391
@jhaygonzaga5391 7 жыл бұрын
w0w sir, you really save me i was about to ask why "intent = builder.build(getApplicationContext);" is giving me error.. so they changed from the context to the name of the activty, i really hate it how they change codes so fast.. again thanks :)))))
@rennylangat
@rennylangat 7 жыл бұрын
Thanks sir
@wassaufkhalid8593
@wassaufkhalid8593 6 жыл бұрын
love you man ..
@rojanbajracharya57
@rojanbajracharya57 7 жыл бұрын
keeps returning to the initial page after clicking?? doesnot allow to select location
@sayedmasihullah6922
@sayedmasihullah6922 7 жыл бұрын
Please check your Google place API for android ...generate it properly ...Somewhere you made mistake ...I got so many good reputation here
@rojanbajracharya57
@rojanbajracharya57 7 жыл бұрын
I have already generated key properly bt still returns ... is there any problem in code??
@sayedmasihullah6922
@sayedmasihullah6922 7 жыл бұрын
No problem in my code ...so many guys have given me thanks here with their success story
@rojanbajracharya57
@rojanbajracharya57 7 жыл бұрын
after clicking, the map shows up for few seconds and then returns back
@rojanbajracharya57
@rojanbajracharya57 7 жыл бұрын
just now the code worked for one time returning place:null, then again as before returning to the page
@androiddeveloper6040
@androiddeveloper6040 3 жыл бұрын
Not working
@himanshudaswani7619
@himanshudaswani7619 8 жыл бұрын
PlacePicker.getPlace(data.this); data error
@androidmine5559
@androidmine5559 8 жыл бұрын
I see your syntax error ... Please write (data , this) not (data.this)
@yashrode7818
@yashrode7818 4 жыл бұрын
pendrive madhe code de!!!!
@yazdani5785
@yazdani5785 7 жыл бұрын
ITS NOT WORK,,
@sayedmasihullah6922
@sayedmasihullah6922 7 жыл бұрын
This not worked for you that means you are poor programmer ...Not my guilty ...Look all the comments ...
@johnconner580
@johnconner580 7 жыл бұрын
Dude this might be working but you are teaching an entirely wrong approach. You are just making it work somehow. The biggest issue is- why are you setting up n onClickListener on a textView? And someone in the comments said that it does not works, you said he is a poor programmer. Seriously ??? If one app is not working for someone, he/she is a poor programmer. Dude, you really need help !
@androidmine5559
@androidmine5559 7 жыл бұрын
I am enough ,I don't need your help..I am Java developer and Android developer as well ..onClickListener is an Interface whose abstract method is setOnClickListener ...It is used to add button click listener ..Oil your own machine
@johnconner580
@johnconner580 7 жыл бұрын
Android Mine java and android developer my foot. You first have to be human to be a developer.... Android mine my foot :D
@androidmine5559
@androidmine5559 7 жыл бұрын
I have more knowledge of human being and I follow it ...now you check your last reply and compare with it .And also you check your first comment ,how crude it is ...And you are teaching me human being ....how funny it is
@johnconner580
@johnconner580 7 жыл бұрын
Android Mine but i am not running a channel and teaching everyone. I only said all this when i had a reason, not when a normal person was struggling with the code.
@androidmine5559
@androidmine5559 7 жыл бұрын
Did you mention it here about your problem? you directly hearted me
Stop, Intel’s Already Dead!
13:47
Linus Tech Tips
Рет қаралды 770 М.
Best Toilet Gadgets and #Hacks you must try!!💩💩
00:49
Poly Holy Yow
Рет қаралды 22 МЛН
SPILLED CHOCKY MILK PRANK ON BROTHER 😂 #shorts
00:12
Savage Vlogs
Рет қаралды 10 МЛН
Location Autosuggestions TextView - [Android Google Maps Course]
13:28
CodingWithMitch
Рет қаралды 96 М.
Why UK 🇬🇧 is going Bankrupt? : Detailed Economic Case Study
20:37
ANDROID PLACE PICKER
15:35
Bamidele Oguntuga
Рет қаралды 33 М.
Custom layouts and graphics in Compose
20:25
Android Developers
Рет қаралды 51 М.
Flutter Google Map With Live Location Tracking
9:08
The Flutter Way
Рет қаралды 263 М.
Android app to Track your location using Google Map API
27:38
How To Get GPS Location In Android
9:16
Filip Vujovic
Рет қаралды 363 М.
Best Toilet Gadgets and #Hacks you must try!!💩💩
00:49
Poly Holy Yow
Рет қаралды 22 МЛН