แก้ไข

แชร์ผ่าน


Axis.Crossing Property

Definition

Gets or sets the location at which an axis is crossed by its associated axis.

public:
 virtual property double Crossing { double get(); void set(double value); };
[System.ComponentModel.Bindable(true)]
[System.ComponentModel.TypeConverter(typeof(System.Web.UI.DataVisualization.Charting.AxisCrossingValueConverter))]
[System.Web.UI.PersistenceMode(System.Web.UI.PersistenceMode.Attribute)]
public virtual double Crossing { get; set; }
[<System.ComponentModel.Bindable(true)>]
[<System.ComponentModel.TypeConverter(typeof(System.Web.UI.DataVisualization.Charting.AxisCrossingValueConverter))>]
[<System.Web.UI.PersistenceMode(System.Web.UI.PersistenceMode.Attribute)>]
member this.Crossing : double with get, set
Public Overridable Property Crossing As Double

Property Value

A double value that represents where an axis is crossed by its associated axis. The default value is NaN.

Attributes

Remarks

Setting this property for a primary axis will determine where the other primary axis crosses it, and similarly setting it for a secondary axis will determine where the other secondary axis crosses it. For example, setting the Crossing property of the primary X-axis determines where the primary Y-axis will cross it.

Four modes can be used for the Crossing property of an axis:

  • "Auto", which means that the crossing value will be set to the minimum or maximum value for the relevant axis. If the axis is primary, the value will be its minimum value, if the axis is secondary it will its maximum value. To set to "Auto" at run time, use a NaN value.

  • "Minimum", which means the crossing value of the axis will be its minimum value. To set to "Minimum" at run-time use a MinValue value.

  • "Maximum", which means the crossing value of the axis will be its maximum value. To set to "Maximum" at run-time use a MaxValue value.

  • A specified double value that is between the minimum and maximum values for the relevant axis. If the crossing value is less then minimum value, or the crossing value is greater than maximum value, an exception will be thrown.

When a non-default crossing value is used, the labels and tick marks of the axis may or may not follow the crossing axis, depending on the IsMarksNextToAxis property setting. By default they will move with the crossing axis.

Applies to