corelibraries-devexpress-dot-xtracharts-dot-series.md
Gets or sets the name of the series.
Namespace : DevExpress.XtraCharts
Assembly : DevExpress.XtraCharts.v25.2.dll
NuGet Package : DevExpress.Charts
[XtraChartsLocalizableCategory(XtraChartsCategory.Misc)]
public string Name { get; set; }
<XtraChartsLocalizableCategory(XtraChartsCategory.Misc)>
Public Property Name As String
| Type | Description |
|---|---|
| String |
A String value representing the name of the series.
|
Note
This property value is dependent on localization. That can be important, for instance, for the ChartControl.GetSeriesByName method.
The following code snippets (auto-collected from DevExpress Examples) contain references to the Name property.
Note
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.
DXBitmap image;
if (!bitmapCache.TryGetValue(element.Series.Name, out image)) {
image = new DXBitmap(totalWidth, totalHeight);
winforms-chart-draw-a-custom-legend-marker-for-a-series/CS/CustomDrawingSample/Form1.cs#L58
private void OnObjectHotTracked(object sender, HotTrackEventArgs e) {
trackedSeriesName = e.HitInfo.InSeries ? ((Series)e.HitInfo.Series).Name : null;
}
winforms-charts-show-chart-legend-with-markers-in-separate-control/CS/Form1.cs#L48
{
if (fakeSeries.Name == series.Name)
{
pane.Title.Visibility = DevExpress.Utils.DefaultBoolean.True;
pane.Title.Text = seriesWithPoints[i].Name;
}
winforms-chart-draw-a-crosshair-cursor/CS/CustomDrawCrosshairCursor/Form1.cs#L52
element.LabelElement.MarkerSize = new Size(15, 15);
element.LabelElement.Text = string.Format("{0}: A={1}; V={2}", element.Series.Name, element.SeriesPoint.Argument, element.SeriesPoint.Values[0]);
}
Dim image As DXBitmap
If Not bitmapCache.TryGetValue(element.Series.Name, image) Then
image = New DXBitmap(totalWidth, totalHeight)
winforms-chart-draw-a-custom-legend-marker-for-a-series/VB/CustomDrawingSample/Form1.vb#L62
Private Sub OnObjectHotTracked(ByVal sender As Object, ByVal e As HotTrackEventArgs)
trackedSeriesName = If(e.HitInfo.InSeries, CType(e.HitInfo.Series, Series).Name, Nothing)
End Sub
winforms-charts-show-chart-legend-with-markers-in-separate-control/VB/Form1.vb#L45
For Each fakeSeries As Series In chart.Series
If Equals(fakeSeries.Name, series.Name) Then
currentSeries = fakeSeries
pane.Title.Visibility = DevExpress.Utils.DefaultBoolean.True
pane.Title.Text = seriesWithPoints(i).Name
Else
winforms-chart-draw-a-crosshair-cursor/VB/CustomDrawCrosshairCursor/Form1.vb#L52
element.LabelElement.MarkerSize = New Size(15, 15)
element.LabelElement.Text = String.Format("{0}: A={1}; V={2}", element.Series.Name, element.SeriesPoint.Argument, element.SeriesPoint.Values(0))
Next
See Also