Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

How to: Manually Generate Vector Items from WKT

To manually provide vector items from the Well-Known Text, do the following.

<Window
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:dxm="http://schemas.devexpress.com/winfx/2008/xaml/map" 
        x:Class="SqlGeometryItemStorageExample.MainWindow"
        Title="MainWindow" Height="350" Width="525">
    <Grid>
        <dxm:MapControl CenterPoint="50,15" ZoomLevel="3">
            <dxm:ImageTilesLayer>
                <dxm:BingMapDataProvider BingKey="Your Bing Key"/>
            </dxm:ImageTilesLayer>
            <dxm:VectorLayer>
                <dxm:SqlGeometryItemStorage>
                    <dxm:SqlGeometryItemStorage.Items>
                        <dxm:SqlGeometryItem WktString="POINT(-0.1275 51.507222 0 25)" Srid="0"/>
                        <dxm:SqlGeometryItem WktString="POINT(12.5 41.9 0 25)" Srid="1"/>
                        <dxm:SqlGeometryItem WktString="POINT(2.3508 48.8567 0 25)" Srid="2"/>
                        <dxm:SqlGeometryItem WktString="POINT(13.38 52.52 0 25)" Srid="3"/>
                        <dxm:SqlGeometryItem WktString="POINT(-3.68 40.4 0 25)" Srid="4"/>
                    </dxm:SqlGeometryItemStorage.Items>
                </dxm:SqlGeometryItemStorage>
            </dxm:VectorLayer>
        </dxm:MapControl>
    </Grid>
</Window>