cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Get GPS coordinates on ANDROID TABLET and SMARTPHONE doesn't work

Hello,

I want in my PowerApps application, a button. And when i click on this button i want that application geolocate ( Latitude and Longitude) the user who click on the button. It works good on PC, but on android tablets and smartphone, the button doesn't work... I don't understand why. because, the GPS position icons is activated on both devices, but when i clickl on the application's geolocate button, it doesn't match.

 

This is my formula :

UpdateContext({var_latitude:Location.Latitude});;UpdateContext({var_longitude:Location.Longitude}).

 

Can you help me please ?

I need that it works on tablets and smartphone.

 

1 ACCEPTED SOLUTION

Accepted Solutions
timl
Super User
Super User

Hi @Anonymous 

With a mobile device, Power Apps can automatically disable location services in order to preserve battery life. There are more details here.

https://docs.microsoft.com/en-gb/powerapps/maker/canvas-apps/functions/function-enable-disable

Therefore, can you try to enable location services before you reference the signal to see if that makes a difference?

Enable(Location);;
UpdateContext({var_latitude:Location.Latitude});;
UpdateContext({var_longitude:Location.Longitude})

View solution in original post

2 REPLIES 2
gabibalaban
Dual Super User
Dual Super User

Hi @Anonymous ,

Are you sure that PowerApps has rights to use location on your tablet / phone ? This is a common behaviour when powerapps is not allowed to use location on a mobile device ?

 

Hope it helps ! 

timl
Super User
Super User

Hi @Anonymous 

With a mobile device, Power Apps can automatically disable location services in order to preserve battery life. There are more details here.

https://docs.microsoft.com/en-gb/powerapps/maker/canvas-apps/functions/function-enable-disable

Therefore, can you try to enable location services before you reference the signal to see if that makes a difference?

Enable(Location);;
UpdateContext({var_latitude:Location.Latitude});;
UpdateContext({var_longitude:Location.Longitude})

Helpful resources

Announcements
Power Platform Call June 2022 768x460.png

Power Platform Community Call

Join us for the next call on August 17, 2022 at 8am PDT.

Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Users online (2,128)