Page 1 of 1

how to use TeeChart with vs2003?

Posted: Wed Mar 29, 2006 9:08 am
by 9529779
i follow the "Tutorial 9 - Internet applications-TeeChart and ASP.NET " instruction, but it doesn't work. the error message is "TChart1 unfefined"


the code:

Create a new ASP.NET application.
Add an Image box to the WebForm.
Right Click on the project's References and add in a reference to the TeeChart Pro ActiveX Control v7 (COM Tab).
In the WebForm's Page_Load event, add in the following code (VB.NET example):
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
TChart1.AddSeries(TeeChart.ESeriesClass.scBar)
TChart1.Series(0).FillSampleValues(10)
TChart1.Height = Image1.Height.Value
TChart1.Width = Image1.Width.Value
TChart1.Export.asPNG.SaveToFile("E:\Inetpub\wwwroot\TestASPNETSol\VBWeb\MyChart.png") 'path to virtual folder
Image1.ImageUrl = "http://localhost/VBWeb/MyChart.png"
End Sub


how should i do?

Posted: Wed Mar 29, 2006 9:16 am
by narcis
Hello,

Have you seen the TeeChart Pro v7 ActiveX examples for VS.NET at C:\Program Files\Steema Software\TeeChart Pro v7 ActiveX Control\Examples\Visual Studio .NET (default english installation path) and the Using TeeChart Pro AX in VStudio NET document available at TeeChart Pro v7 ActiveX program group?

BTW: Which TeeChart version are you using? If you use TeeChart Pro v7 ActiveX you should read its specific tutorials and examples. The same applies for TeeChart for .NET.