Search code examples
androidgmsplacepicker

Display Google location in Android layout


I am using Google Place Picker to get the user current location and send it to the other user in a chat dialog, but what I want is to display that location in the chat dialog as a message element.

target image

How can I do that?


Solution

  • My suggestions would be to get the picked location's latitude and longitude, then send it to user/server as per your system congfiguration. Then in other user side, show the google map view in inside chatbox, you can use MapFragment for this, then add location marker at the received latitude and longitude in google map.