Skip to main content
Solved

Mobile App - Can't get GPS Location on iPhone

  • December 2, 2022
  • 7 replies
  • 202 views

Nice day.

I have a customization screen on mobile to get GPS Location of current user when they press a button. The screen works like a charm on Android device but couldn’t work on iPhone even though I have enabled Location Permission for Acumatica in Settings → Acumatica → Location.

My customization screen is as below.

add screen GP30IC10 {
  openAs = Form
  add container "Params" {
    add field "Latitude" {
      forceIsDisabled = true
    }
    add field "Longitude" {
      forceIsDisabled = true
    }
    add field "GPSLocation" {
      forceIsVisible = false
      special = GpsCoords
    }

    add layout "Action" {
      layout = "Inline"
      add recordActionLink "ClockIn"
      add recordActionLink "ClockOut"    
    }

    add recordAction "ClockIn" {
      behavior = Record
    }

    add recordAction "ClockOut" {
      behavior = Record
    }
  }
}

Does anybody know how to solve the problem? Do I miss any configuration on iPhone?

Thank in advance

Best answer by rhooper91

Hey @larry88,

  1. Users → Location Tracking → I usually set for 1 minute to get good data, then I set the timeframe window for a time that I’m actively testing. Ensure that the time zone matches your testing time zone as you might not get data if you fall outside of it.
  2. I then use my mobile device or emulator to log in to get some test data
  3. Then I come to the OOTB inquiry, Location Tracking History, to see if I got any data. If I didn’t, then I didn’t set something up or my mobile device is not sending a location properly.

Note that emulators are funky and might send GPS coordinates based on a static value or your computers ip address location or not at all.

Hope this helps! It also might help you debug iOS issues if you are registering locations natively out of your android device and not the iOS device.

View original
Did this topic help you find an answer to your question?

7 replies

RaphaelPfaff12
Semi-Pro II

Do you enable the option for tracking in the User Screen (SM201010)?


  • Author
  • Freshman I
  • 5 replies
  • December 2, 2022
RaphaelPfaff12 wrote:

Do you enable the option for tracking in the User Screen (SM201010)?

Thank @RaphaelPfaff12 ,
I have just enabled and try again however it still does not work.


  • Author
  • Freshman I
  • 5 replies
  • December 6, 2022

Hi, can anybody support me the issue?


Forum|alt.badge.img+1
  • Varsity III
  • 64 replies
  • December 6, 2022

@larry88,

It might not be exactly what you are looking for, but I have had success with using the following tables in conjunction with the user location tracking process.

The system queries based on interval instead of by pressing a button. I use it by querying the table for a recent location pulled in the last 1-2 minutes and then save that as my location. Just an alternative option if you aren’t able to get the button working on the iOS.

You could still use the button, but instead of pulling an active location, it would query that table and save the most recent location, so long as your intervals are within 1-2 minutes of the pull.


  • Author
  • Freshman I
  • 5 replies
  • December 7, 2022
rhooper91 wrote:

@larry88,

It might not be exactly what you are looking for, but I have had success with using the following tables in conjunction with the user location tracking process.

The system queries based on interval instead of by pressing a button. I use it by querying the table for a recent location pulled in the last 1-2 minutes and then save that as my location. Just an alternative option if you aren’t able to get the button working on the iOS.

You could still use the button, but instead of pulling an active location, it would query that table and save the most recent location, so long as your intervals are within 1-2 minutes of the pull.

Many thanks for your support @rhooper91 , can you guide me how to enable the feature? 
From my local, the table FSGPSTrackingHistory is empty even though I have enabled Location Tracking is Users screen.


Forum|alt.badge.img+1
  • Varsity III
  • 64 replies
  • Answer
  • December 8, 2022

Hey @larry88,

  1. Users → Location Tracking → I usually set for 1 minute to get good data, then I set the timeframe window for a time that I’m actively testing. Ensure that the time zone matches your testing time zone as you might not get data if you fall outside of it.
  2. I then use my mobile device or emulator to log in to get some test data
  3. Then I come to the OOTB inquiry, Location Tracking History, to see if I got any data. If I didn’t, then I didn’t set something up or my mobile device is not sending a location properly.

Note that emulators are funky and might send GPS coordinates based on a static value or your computers ip address location or not at all.

Hope this helps! It also might help you debug iOS issues if you are registering locations natively out of your android device and not the iOS device.


  • Author
  • Freshman I
  • 5 replies
  • December 11, 2022
rhooper91 wrote:

Hey @larry88,

  1. Users → Location Tracking → I usually set for 1 minute to get good data, then I set the timeframe window for a time that I’m actively testing. Ensure that the time zone matches your testing time zone as you might not get data if you fall outside of it.
  2. I then use my mobile device or emulator to log in to get some test data
  3. Then I come to the OOTB inquiry, Location Tracking History, to see if I got any data. If I didn’t, then I didn’t set something up or my mobile device is not sending a location properly.

Note that emulators are funky and might send GPS coordinates based on a static value or your computers ip address location or not at all.

Hope this helps! It also might help you debug iOS issues if you are registering locations natively out of your android device and not the iOS device.

Hi @rhooper91 , thank for your support, it already worked after enabling Field Service module.
Unfortunately, we don’t have Field Service on our Production.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings