At the end of installing the component, we got an error message "To run this application, you first must install one of the following versions of .NET framework: v2.0.50727" I hit "OK" on the error message and installation completes successfully and installs the component. Apparently, I am able to add Teechart control to the project and edit properties and populate the chart with Series.FillSamplevalues() and get the chart working.
But I am having hard time with populating the chart with data from a dataset
These are the steps I followed.
Added a reference in the project to Teechart, dragged and dropped a Webchart cotrol. added a Getchart.aspx page with appropriate code for Page_Load()
On the webform where I have the webchart, I have the following code.
Code: Select all
Protected WithEvents WebChart1 As Steema.TeeChart.Web.WebChart
Private CandleSeries1 As Steema.TeeChart.Styles.Candle
Private Chart1 As Steema.TeeChart.Chart
I have verified Datatable tab has data in it with 90 rows.
Code: Select all
Public Sub GenerateTeeChart(ByVal tab As DataTable)
//this is what the examples code illustrated in the help documentation
Chart1 = WebChart1.Chart
CandleSeries1 = New Steema.TeeChart.Styles.Candle
Chart1.Series.Add(CandleSeries1)
CandleSeries1.YValues.DataMember = tab.Columns("Throughput").ToString()
CandleSeries1.LabelMember = tab.Columns("Time").ToString()
CandleSeries1.DataSource = tab
Chart1.Legend.Visible = True
Chart1.Axes.Bottom.Labels.Angle = 90
Steema.TeeChart.Themes.ColorPalettes.ApplyPalette(Chart1.Chart, 7)
End Sub
I see the axes and there is only one label "0" at the center of left "Y" axis and one label "12:00AM" on bottom X Axis. Nothing else on the plot.
What am I missing here? Please help