Start a Project

Android Google Places Autocomplete

The autocomplete service in the Google Places API for Android returns place predictions in response to user search queries.

Add the dependency to your buid.gradile

Add the following tag to your  AndroidManifest.xml under application tag.

Creating the layouts of the main GooglePlacesAutocompleteActivity

Place is an instance of PlaceAutocompteFragment setOnPlaceSelectedListener to place instance.

You can filter the places which should be listed in suggestion, Like suppose if you want to show just city name instead of entire address, you can add the filter like this:

 

 

 

 

Exit mobile version