Back to Devexpress

XYDiagram2D.ScrollAxisYTo(Double) Method

wpf-devexpress-dot-xpf-dot-charts-dot-xydiagram2d-dot-scrollaxisyto-x28-system-dot-double-x29.md

latest2.3 KB
Original Source

XYDiagram2D.ScrollAxisYTo(Double) Method

Scrolls the Y-axis to the specified position.

Namespace : DevExpress.Xpf.Charts

Assembly : DevExpress.Xpf.Charts.v25.2.dll

NuGet Package : DevExpress.Wpf.Charts

Declaration

csharp
public void ScrollAxisYTo(
    double yPosition
)
vb
Public Sub ScrollAxisYTo(
    yPosition As Double
)

Parameters

NameTypeDescription
yPositionDouble

A Double value that specifies the position to which to scroll. The value should be in the [0;1] range where 0 defines the beginning of the axis and 1 is the end.

|

Remarks

The following code scrolls a diagram to the position passed as a parameter:

csharp
XYDiagram2D diagram = (XYDiagram2D)chart.Diagram;
diagram.ScrollAxisYTo(0.3);
vb
Dim diagram As XYDiagram2D = CType(chart.Diagram, XYDiagram2D)
diagram.ScrollAxisYTo(0.3)

Before you call the ScrollAxisXTo method, ensure that the diagram’s EnableAxisXNavigation and EnableAxisYNavigation properties are enabled.

To verify whether it is possible to scroll the Y-axis, call the XYDiagram2D.CanScrollAxisYTo method.

See Also

ScrollAxisXTo(Double)

Zoom and Scroll in 2D XY-Charts

XYDiagram2D Class

XYDiagram2D Members

DevExpress.Xpf.Charts Namespace