Get Lattitude Longitude and My current location


I want to get lat and long of my current location but I am not finding any solution can anyone please help…

You can get the Latitude and Longitdude with the “Map” component.

You can also use the following blocks with the “Location Sensor” component:

Use the Location Sensor

I tried using location sensor but not working

You must ask for permission to use the location first.

Needed permissions:


Thanks can you please share aia if possible

Sure, give me a second

No permission required, if they enable location service, immediatly you can get it by using google map which is inbuild in the kodular app

location.aia (2.1 KB)

Just use these two blocks to get lattitude and longitude

blocks(1) blocks

1 Like

Thanks I will try this

I will try this also

getlocationwhenGPSon.aia (2.0 KB)

This aia will give geo value immediatly but user need to enable GPS on but no need to ask any permission


not correct what if user does not move then the event will also not fire i prefer you the best use location sensor component or use the extension by @juananton1991

1 Like

Thanks for the aia

1 Like

It works well even if you are ideal in position or moving .
I have tested and still working fine in my school attendance app.

1 Like

this is not working values are coming as 0

You’ll have to wait a few seconds and refresh again as it says in the AIA

this worked thanks