How can I take user location and allow to adjust it on the map

Hello everyone, I am a beginner in the OutSystems platform and I want to develop a mobile application that allows the user to place their ads, but I don't know how to take user location and at the same time allow the user to adjust the map to determine the desired location, like this picture... can anyone help me please Thanks in advanced...


mvp_badge
MVP

Hi Afnan,

Welcome to the OutSystems community.

To pick a location in mobile you could use the following Forge component build by my fellow MVP Nikhil Gaur:

Google Map Location Picker for Reactive Web and Mobile Apps

There is a sample application too in the Forge that will show you how to use the component in your application:

Google Map Location Picker Mobile - Sample App

To get the current location in an OutSystems mobile application you can use the:

Location Plugin from OutSystems R&D

Kind regards,

Daniel


Hi Daniël,

I am a very beginner in the OutSystems platform so can help me please how can I use those Forge components, I installed those components but unfortunately, I did not understand them... I appreciate your cooperation.  

Hi, friend. 

I did this application some months ago and I think that's exactly what you need.

In the CS module you will find a GetUserLocation Client Action wich contains a javascript to get location ready to use. 

In interface module you will find a block with a map that shows the location passed by parameter. 

I did not that to show any ads. You can use another option like Leaflet if you find any issue with google maps.

Let me know if it helps.


Kind regards.

OSRegister.oap

Hi Lenon,

can please explain to me in detail how I can use it and integrated in my mobile app because I am beginner in the OutSystems platform. thanks 


Hi!

In this case, is not an 'integration'. My application will be something like a template to you.

My project was made in reactive, so they are 100% compatible.

Maybe you're not able to copy and paste, so you'll need to build the same client action in you envoironment.


If you donot want to register with credit card to obtain an apikey for the Google map feature, there is a free alternative:

https://www.outsystems.com/forge/component-overview/6907/leafletjs-reactive

The developer Vincent Koning is very active and has made it easy to use component.


Yes, when I try to open any map this message "for development purposes only" and yes I have apikey but I do not want to register with a credit card, can you explain how can I use this because I installed it but I did not know how to use it,

Hi Afnan,

You can start by examining this demo:

https://www.outsystems.com/forge/component-overview/7518/leaflet-draw-demo


The reactive component als has extensive documentation.

https://www.outsystems.com/forge/Component_Documentation.aspx?ProjectId=6907&ProjectName=leafletjs-reactive


Please look at this first. If you have any questions afterwards, please ask. 

Good luck!

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.