0
我通過我的數據表列sdescr試圖循環並使用在列,我的x軸的標籤文本,但它不是工作我收到此錯誤捷思圖X軸標籤
價值鍵入 'System.Collections.Generic.List(的 字符串)'不能轉換爲 '1維數組的字符串'。
For i As Integer = 0 To myCurve1.Points.Count - 1
Dim pt As PointPair = myCurve1.Points(i)
' Create a text label from the Y data value
Dim text As New TextObj(pt.Y.ToString("f0"), pt.X, pt.Y + 0.1, CoordType.AxisXYScale, AlignH.Left, AlignV.Center)
text.ZOrder = ZOrder.A_InFront
text.FontSpec.Angle = 90
myPane.GraphObjList.Add(text)
Dim labels As New List(Of String)
For Each row As DataRow In tablegraph.Rows
labels = row.Item("SDESCR")
Next row
myPane.XAxis.Scale.TextLabels = labels
myPane.XAxis.Type = AxisType.Text
Next