IM getting this error when i try to run Teecharts ActiveX control in asp.net
environment
can some one help me in it
Regards Moid Iqbal
Catastrophic failure
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.
Exception Details: System.Runtime.InteropServices.COMException: Catastrophic
failure
Source Error:
Line 59: dr = com.ExecuteReader
Line 60: Dim tchart As New TeeChart.TChart()
Line 61: tchart.Series(0).DataSource = dr
Line 62: tchart.Series(0).YValues.ValueSource = "tons"
Line 63: tchart.Series(0).LabelsSource = "shift date"
Source File: D:\Inetpub\wwwroot\Accuweigh\subreports\teechartpr eview.aspx.vb
Line: 61
Stack Trace:
[COMException (0x8000ffff): Catastrophic failure]
TeeChart.TChartClass.Series(Int32 SeriesIndex) +0
Accuweigh.teechartpreview.assd() in
D:\Inetpub\wwwroot\Accuweigh\subreports\teechartpr eview.aspx.vb:61
Accuweigh.teechartpreview.Page_Load(Object sender, EventArgs e) in
D:\Inetpub\wwwroot\Accuweigh\subreports\teechartpr eview.aspx.vb:46
System.Web.UI.Control.OnLoad(EventArgs e) +67
System.Web.UI.Control.LoadRecursive() +29
System.Web.UI.Page.ProcessRequestMain() +724
----------------------------------------------------------------------------
----
Version Information: Microsoft .NET Framework Version:1.0.3705.288; ASP.NET
Version:1.0.3705.288
Dim con As New OdbcConnection("DRIVER={MySQL ODBC 3.51 Driver}; SERVER=
localhost; DATABASE = accuweigh ; UID = root; PASSWORD=;")
Dim dr As OdbcDataReader
con.open()
Dim com As New OdbcCommand("select date_format(chronology.shiftdate,'%b
%d,%x') as 'shift date',round(sum(draglinecycles.tons),2) as 'tons' from
chronology left join draglinecycles on draglinecycles.excavator =
chronology.excavator and draglinecycles.recindx = chronology.recindx group
by 'excavator' order by 'excavator'", con)
dr = com.ExecuteReader
Dim tchart As New TeeChart.TChart()
tchart.Series(0).DataSource = dr
tchart.Series(0).YValues.ValueSource = "tons"
tchart.Series(0).LabelsSource = "shift date"
Response.BinaryWrite(tchart.Export.asPNG.SaveToStr eam())
Ive Also used this code but the error was the same as given above
Dim con As New ADODB.Connection()
Dim rs As New ADODB.Recordset()
con.ConnectionString = "DRIVER={MySQL ODBC 3.51
Driver};SERVER=localhost;DATABASE=accuweigh;UID=ro otPASSWORD=;"
con.Open()
rs.Open("select date_format(chronology.shiftdate,'%b %d,%x') as 'shift
date',round(sum(draglinecycles.tons),2) as 'tons' from chronology left join
draglinecycles on draglinecycles.excavator = chronology.excavator and
draglinecycles.recindx = chronology.recindx group by 'excavator' order by
'excavator'", con)
Dim tchart As New TeeChart.TChart()
tchart.Series(0).DataSource = rs
tchart.Series(0).YValues.ValueSource = "tons"
'tchart.Series(0).LabelsSource = "shift date"
'Response.BinaryWrite(tchart.Export.asPNG.SaveToSt ream())