Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
New Contributor
niharonly
Posts: 6
Registered: ‎01-27-2013
My Device: BB10
My Carrier: Airtel

How to get current location on map?

Hi,

I want my current location on map. I have searched a lot but cant get the proper solution. Anyone knows how to get it?

Please reply asap..

 

Thanks in advance..

Please use plain text.
Developer
simon_hain
Posts: 16,004
Registered: ‎07-29-2008
My Device: Z10 LE
My Carrier: O2 Germany

Re: How to get current location on map?

You can use a LocationMapInvoker as an attached object in QML.
I am not sure if you have to set the latitude and longitude as we use the invoker only with other coordinates, you'll have to test that.

We use this code to invoke the maps app:
locationInvoker.locationLatitude = latitude
locationInvoker.locationLongitude = longitude
locationInvoker.locationName = locationName
locationInvoker.locationDescription = locationDescription
locationInvoker.go()
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter
Please use plain text.