Menu

Map Long lat

Gordon
2014-04-17
2014-09-20
  • Gordon

    Gordon - 2014-04-17

    Hi, i know that I can get the long/lat from a MapView.. Is that the only way? Is using location sensor with firemonkey the best way? Also, Can I detect if location services are on or off? I want to disallow my app if its off.

     

    Last edit: Gordon 2014-04-17
  • Gordon

    Gordon - 2014-04-17

    Also, is there a way to see if they location services are active, and if not, pop up a dialog box asking for permission to turn it back on ? I want to force the user to have location services on, or the app wont run.

     
  • Babak Yaghoobi

    Babak Yaghoobi - 2014-04-23

    Hi Gordon

    You can check is locationServicesEnabled or not, if enabled you can continue your work if not you can disable some your app features,

    check this : LocationSensor1.Active

    Regards

     
  • Gordon

    Gordon - 2014-09-18

    Can you tell me where I can find the property locationServicesEnabled ??

    I cant seem to find it.. I want to be able to test to see if the location services are on for this app

     
  • Gordon

    Gordon - 2014-09-19

    Any ideas about this? Ive searched high and low to figure out how to tell if locationservices are enabled for my app.. Cant find any way to do it.. Any ideas? Im really stuck..

     
  • Gordon

    Gordon - 2014-09-20

    After banging my head, I figured out.. that

    If (Not TCLLocationManager.OCClass.locationServicesEnabled) or (TCLLocationManager.OCClass.authorizationStatus <> kCLAuthorizationStatusAuthorized) then
    Begin

    End;

    does the trick.. This will look at the app and global location service setting..
    Now I can close my app if its not enabled.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.