Skip to main content
All docs
V25.1
  • DevExpress v25.1 Update — Your Feedback Matters

    Our What's New in v25.1 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

    MeasurementToolbarOptions.ShowDistanceButton Property

    Specifies whether the Add Distance Ruler button is displayed on the Measurements toolbar.

    Namespace: DevExpress.XtraMap

    Assembly: DevExpress.XtraMap.v25.1.dll

    NuGet Package: DevExpress.Win.Map

    #Declaration

    [DefaultValue(true)]
    public bool ShowDistanceButton { get; set; }

    #Property Value

    Type Default Description
    Boolean true

    true if the Add Distance Ruler button is visible; otherwise, false.

    #Property Paths

    You can access this nested property as listed below:

    Object Type Path to ShowDistanceButton
    Measurements
    .ToolbarOptions .ShowDistanceButton

    #Remarks

    image

    The following code hides the Add Area Ruler button and displays the Add Distance Ruler button:

    mapControl1.Measurements.ShowToolbar = true;
    mapControl1.Measurements.ToolbarOptions.ShowDistanceButton = true;
    mapControl1.Measurements.ToolbarOptions.ShowAreaButton = false;
    
    See Also