ElementSelectionMode Enum

Lists selection modes available for the end-user.

Namespace: DevExpress.XtraTreeMap

Assembly: DevExpress.XtraTreeMap.v20.1.dll

Declaration

public enum ElementSelectionMode
Public Enum ElementSelectionMode

Members

Name Description
None

Selection is disabled.

Single

One item can be selected at a time.

Multiple

Several items can be selected at the same time.

Extended

Extended single selection mode, allowing you to select several items with the SHIFT key held down.

Related API Members

The following properties accept/return ElementSelectionMode values:

Remarks

Values of this enumeration are used to specify the HierarchicalChartControlBase.SelectionMode property.

Examples

To specify end-user permissions, use the TreeMapControl.EnableHighlighting and HierarchicalChartControlBase.SelectionMode properties.

using DevExpress.XtraTreeMap;
using System;
using System.Windows.Forms;

namespace HighlightingAndSelection {
    public partial class Form1 : Form {
        public Form1() {
            InitializeComponent();
        }

        private void Form1_Load(object sender, EventArgs e) {
            chkEnableHighlighting.Checked = treeMap.EnableHighlighting;

            lbSelectionMode.DataSource = Enum.GetValues(typeof(ElementSelectionMode));
            lbSelectionMode.SelectedValue = treeMap.SelectionMode;
        }

        private void chkEnableHighlighting_CheckedChanged(object sender, EventArgs e) {
            treeMap.EnableHighlighting = chkEnableHighlighting.Checked;
        }

        private void lbSelectionMode_SelectedIndexChanged(object sender, EventArgs e) {
            treeMap.SelectionMode = (ElementSelectionMode)lbSelectionMode.SelectedValue;
        }
    }
}
See Also