A little help needed please! I am having some trouble trying to create a chart programmatically by using the column names of a datatable for the x-axis and the values in the first row for the y values.
I am trying to add a tooltip to each x-axis item but no matter what I try, I cannot get this to work.
After creating the x-axis items using
RadChart2.PlotArea.XAxis.AddRange(1, 7, 1)
I have tried looping through each x-axis items using this code
For i As Int16 = 0 To Me.RadChart2.PlotArea.XAxis.Items.Count() - 1 |
Me.RadChart2.PlotArea.XAxis.Item(i).ActiveRegion.Url = "javascript:void(0)" |
Me.RadChart2.PlotArea.XAxis.Item(i).ActiveRegion.Tooltip = "some tooltip text" |
Next |
I have tried this code in the routine which creates the chart (called from page.load) and in the chart prepaint event but no success.
If I define the activeregion.tooltip and activeregion.url in chart definition in the aspx page, then tooltips are displayed as expected over the x-axis items.
There are a number of other things I cannot get to work programmatically, such as the width of the x-axis item textblock, but I would really like to get the tooltips working.
Can you tell me what I'm doing wrong? I'm sure I must be missing something really simple!
Thanks,
Jonathan