Have a look at https://docs.mendix.com/appstore/modules/nanoflow-commons this provides geolocation support.
This is the documentation of the nanoflow commons module from the market place. You can also do a search on the mendix marketplace with “geo” as search term to find more modules supporting geolocation.