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

MapCustomElement Class

The class used to draw any custom element on a map.

Namespace: DevExpress.XtraMap

Assembly: DevExpress.XtraMap.v24.2.dll

NuGet Package: DevExpress.Win.Map

#Declaration

public class MapCustomElement :
    MapPointer

The following members return MapCustomElement objects:

#Remarks

The following image shows an example of a map custom element.

MapCustomElementExample

Important

The custom element does not provide any default image and the element displays only a text if the image is not specified.

#Example

View Example

var customElement = new MapCustomElement() { Location = new GeoPoint(50, 50), Text = "This is a MapCustomElement object" };
var image = new Bitmap(imageFilePath);
customElement.Image = new Bitmap(image, new Size(40, 40));
ItemStorage.Items.Add(customElement);

#Inheritance

Object
MapItem
MapPointer
MapCustomElement
See Also