CustomDrawSeriesPointEventArgs.LabelText Property

Gets or sets the text of a label for the point currently being painted.

Namespace: DevExpress.XtraCharts

Assembly: DevExpress.XtraCharts.v21.2.dll


public string LabelText { get; set; }

Property Value

Type Description

A String representing a label’s text.


Use the LabelText property to change the text of a label for the point currently being painted when handling the ChartControl.CustomDrawSeriesPoint event. For a series with points containing two labels, you can also specify the CustomDrawSeriesPointEventArgs.SecondLabelText property.


If the LabelText property is set to Empty or null (Nothing in Visual Basic), this label will be hidden.


Handle the ChartControl.CustomDrawSeriesPoint event to conditionally hide series labels. In the event handler, change the CustomDrawSeriesPointEventArgs.LabelText property value to String.Empty to hide a label.


Handling the WebChartControl.CustomDrawSeriesPoint (ChartControlSettings.CustomDrawSeriesPoint) event is necessary to perform the same for the Chart Control for ASP.NET and MVC.

private void OnCustomDrawSeriesPoint(object sender, CustomDrawSeriesPointEventArgs e) {
    if (e.SeriesPoint.Values[0] < 1) {
        e.LabelText = String.Empty;

The following code snippets (auto-collected from DevExpress Examples) contain references to the LabelText property.


The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

See Also