Get Location
Finds where the iPad is right now.
Category: Device · Can fail (wrap it in Try to handle that) · Takes time: the next step waits for it
#When to use it
Use it to find where the iPad is right now: the weather here, places nearby, where an entry was made.
#Example
A weather screen's When Loading:
- Get Location with Into: here.
- Call API with Query fields
latitude(⚡︎ → Formula…here.latitude) andlongitude(here.longitude).
#Good to know
- It needs Location. The first time, your app shows the reason you wrote under Data & Logic → Permissions, then iPadOS asks.
- It saves
latitude,longitudeandaccuracy(in meters). - If there's no location within 15 seconds, or Location is turned off, the step fails.
#Add it
Select a view, open the Inspector's Actions tab, pick when it runs, tap Add action and choose Get Location (under Device). Tap the step to open its settings.
#Settings
| Setting | What it does | Kind | Default |
|---|---|---|---|
| Into | Where to save it. | Variable | Required |
#What it gives back
{ latitude, longitude, accuracy } (accuracy in meters).