DataPoint.SetValueY(Object[]) 方法

定義

設定單一資料點的 Y 值。Sets the Y-value(s) of a single data point.

public:
 void SetValueY(... cli::array <System::Object ^> ^ yValue);
public void SetValueY (params object[] yValue);
member this.SetValueY : obj[] -> unit
Public Sub SetValueY (ParamArray yValue As Object())

參數

yValue
Object[]

集合中 DataPoint 物件的 Y 值。The Y-value(s) of a DataPoint object in the collection. 格式化為一個值或多個以逗號分隔的值。Formatted as one or more values separated by commas.

備註

SetValueY屬性是用來在執行時間設定資料點的 Y 值 (s) 。The SetValueY property is used to set the Y-value(s) of a data point at run time.

除了反升、k 線和股票圖以外,所有圖表類型都只需要一個 Y 值。Only one Y-value per point is required for all chart types except for bubble, candlestick and stock charts. 這些圖表類型需要一個以上的 Y 值,因為其中一個資料點是由多個值所組成。These chart types require more than one Y-value because one data point consists of multiple values. 例如,若要繪製一個股票圖資料行,則需要四個值: [高]、[低]、[開啟] 和 [收盤] 值。For example, to plot one stock chart column, four values are required: high, low, open and close values.

double當用來抓取多個 Y 值時,這個屬性會傳回值的陣列。This property returns an array of double values when used to retrieve multiple Y-values.

重要

YValuesPerPoint屬性會決定中所有資料點可以擁有的最大 Y 值數目 SeriesThe YValuesPerPoint property determines the maximum number of Y-values that all data points in a Series can have. 如果您指定的 Y 值數目超過允許的數目,則會引發例外狀況。If you specify more than the allowable number of Y-values, an exception will be raised.

請參閱下表,以取得可用於物件類型參數的有效 .NET Framework 類型的完整清單:Refer to the following table for a complete listing of valid .NET Framework types that can be used for the object type parameter:

StringString DatetimeDateTime DoubleDouble
DecimalDecimal SingleSingle Int32Int32
UInt32UInt32 Int64Int64 UInt64UInt64

適用於