I'm an Ultrachart newbie and I've created a simple line chart (code below) by building my data table and
binding it to the chart control. However, my x-axis labels are showing the defaults Row#0, Row#1,
Row#2, Row#3 values. How do I set these values in the code-behind? Thanks much!
dt.Columns.Add("P2-09", GetType(System.Double))
dt.Columns.Add("P1-09", GetType(System.Double)) dt.Columns.Add( "P3-08", GetType(System.Double)) For cnt = 0 To lower dt.Rows.Add(
dt.Columns.Add(
dt.Rows.Add(
New Object() {CDbl(dArray(cnt, 1)), CDbl(dArray(cnt, 2)), CDbl(dArray(cnt, 3))}) Next
igLineChart.Data.SwapRowsAndColumns =
True
igLineChart.DataSource = dt
igLineChart.DataBind()
igChart.ColorModel.CustomPalette =
igChart.Section508Compliant =
cnt = 0
the best way is to add a string column to your datatable.
you can also use the Data.SetRowLabels method.
I couldn't get the string column to work in the data table, but the SetRowLabels works great! Thanks for the quick response!