Gets the current location of the Device taking in consideration a new flag to ignore possible errors on the operation. The two errors that are considered are:
- Location Services are disabled. The message shown is GXM_LocationServicesAreDisabled
- The app does not have permissions to get the Location Services. The message shown is GXM_CouldNotGetLocationInformation
Available in GeneXus V17
||Specifies the minimum accuracy required. This accuracy is specified in meters, 0 - ignores the accuracy of the GPS information.
||Specifies, in seconds, the maximun waiting time to get a location with the desired accuracy. If the device cant get a location in the specified time with the required accuracy it returns the best location available. 0 means don't wait.
||Specifies if it is necessary to include the heading and speed information in the result.
||Specifies where the execution of this operation cancels other operation or this operations error are ignored by the application. If an error ocurred and the ignore error flag is set to true an empty value is returned. If an error ocurred and the ignore errors flag is set to false then a msg will prompt the user with a legen saying "Could not get location information" this message can be translated form the language option.
For example, minAccuracy has a value of 10 meters and the return value has an accuracy of 500 meters, if the time set in the timeout parameter was not reached yet, it will attempt to obtain a more precise data. If that time was reached and the desired accuracy was not obtained, the method won't return any location.
type: LocationInfo SDT
A LocationInfo Structure Data Type loaded with the information gathered from the GPS.
It functionality is similar to that provided by the GetMyLocation method of the Geolocation external object
In some Android devices, it is necessary to be activated the locator google service in order to work properly with this feature