corelibraries-devexpress-dot-xtracharts-dot-xydiagrampanecollection-dot-getpanebyname-x28-system-dot-string-x29.md
Gets a pane within the collection by its name.
Namespace : DevExpress.XtraCharts
Assembly : DevExpress.XtraCharts.v25.2.dll
NuGet Package : DevExpress.Charts
public XYDiagramPane GetPaneByName(
string name
)
Public Function GetPaneByName(
name As String
) As XYDiagramPane
| Name | Type | Description |
|---|---|---|
| name | String |
A String which specifies the name of the pane to find.
|
| Type | Description |
|---|---|
| XYDiagramPane |
An XYDiagramPane object that represents the pane with the specified name.
|
Note that this method finds only the first occurrence of a pane with the specified name. If no element with the specified name is found, then this method returns null ( Nothing in Visual Basic).
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the GetPaneByName(String) method.
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.
winforms-chart-add-an-additional-legend-to-a-chart/CS/LegendsSamples/Form1.cs#L37
// Position it.
macdLegend.DockTarget = diagram.Panes.GetPaneByName("macdPane");
macdLegend.AlignmentHorizontal = LegendAlignmentHorizontal.Left;
winforms-chart-add-an-additional-legend-to-a-chart/VB/LegendsSamples/Form1.vb#L39
' Position it.
macdLegend.DockTarget = diagram.Panes.GetPaneByName("macdPane")
macdLegend.AlignmentHorizontal = LegendAlignmentHorizontal.Left
See Also