We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

OSM example

Thread ID:





150903 Jan 23,2020 07:04 PM UTC Jan 24,2020 11:01 AM UTC WPF 1
Tags: SfMaps
Asked On January 23, 2020 07:04 PM UTC

Please, I have a problem with OSM in Maps. (WPF)
Could you write a typical sample of using the OSM map with GPS coordinates in collection and the pin with label.
Thank you. 

Ramya Soundar Rajan [Syncfusion]
Replied On January 24, 2020 11:01 AM UTC

Hi Peter, 
Thanks for contacting Syncfusion support. 
We have prepared the simple SfMaps sample with binding the Markers property from the ViewModel. Added marker label and icon by using the MarkerTemplate property as like in below code. 
        <syncfusion:SfMap x:Name="maps"> 
                <syncfusion:ImageryLayer x:Name="imageryLayer" Markers="{Binding Models}" LayerType="OSM" > 
                            <StackPanel Orientation="Horizontal" Margin="-12,-30,0,0"> 
                                <Image Source="pin.png" Height="30"/> 
                                <TextBlock Margin="5,5,0,0" Foreground="Red" HorizontalAlignment="Center" FontSize="10" FontFamily="Segoe UI" Text="{Binding Data.Name}"/> 
Please find the sample from below location. 
Output Screenshot: 


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon