For a list of all members of this type, see TChart Members


System.Object
   System.MarshalByRefObject
      System.ComponentModel.Component
         System.Windows.Forms.Control
[Serializable]
public class TChart : Control , IComponent, IDisposable, IOleControl
, IOleObject, IOleInPlaceObject, IOleInPlaceActiveObject, IOleWindow
, IViewObject, IViewObject2, IPersist, IPersistStreamInit, IPersistPropertyBag
, IPersistStorage, IQuickActivate, ISupportOleDropSource, IDropTarget
, ISynchronizeInvoke, IWin32Window, IArrangedElement, IBindableComponent
, IKeyboardToolTip, ISerializable, IChart

Remarks

TChart is the central component in TeeChart library for Windows Forms and is the container for all other TeeChart objects. The diagram below indicates the main TeeChart objects that can be found within the TChart class:



TChart objects can be added to Windows Forms both at design and run-time; at run-time we would use code similar to the following:
[C#] 
private void Form1_Load(object sender, System.EventArgs e) {
     Steema.TeeChart.TChart tChart1 = new Steema.TeeChart.TChart();
     tChart1.Header.Lines = new string[] {"TeeChart"};
     tChart1.Location = new System.Drawing.Point(32, 32);
     tChart1.Name = "tChart1";
     tChart1.Size = new System.Drawing.Size(528, 264);
     tChart1.TabIndex = 0;

     this.Controls.AddRange(new System.Windows.Forms.Control[] {tChart1});
}

[VB.Net]
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
    Dim TChart1 As Steema.TeeChart.TChart = New Steema.TeeChart.TChart()
    TChart1.Header.Lines = New String() {"TeeChart"}
    TChart1.Location = New System.Drawing.Point(32, 32)
    TChart1.Name = "TChart1"
    TChart1.Size = New System.Drawing.Size(528, 264)
    TChart1.TabIndex = 0

    Me.Controls.AddRange(New System.Windows.Forms.Control() {TChart1})
End Sub

You can also add series to a Chart using code:

[C#] 
Steema.TeeChart.Styles.Bar bar1 = new Steema.TeeChart.Styles.Bar(tChart1.Chart);
bar1.FillSampleValues(20);
[VB.Net]
Dim Bar1 As New Steema.TeeChart.Styles.Bar(TChart1.Chart)
Bar1.FillSampleValues(20)

or...

[C#]
tChart1.Series.Add(new Steema.TeeChart.Styles.Pie());
tChart1.Series[0].FillSampleValues(20);
[VB.Net]
TChart1.Series.Add(New Steema.TeeChart.Styles.Pie())
TChart1.Series(0).FillSampleValues(20)

Any number of TChart objects can co-exist on a single Windows Form. To use TeeChart within a Web Form environment please use the Steema.TeeChart.Web.WebChart class.

For an indepth look at how to create Charts with TeeChart see the TeeChart Tutorials.

Requirements

Namespace: Steema.TeeChart Namespace

Assembly: TeeChart.dll

See Also

TChart members | Steema.TeeChart Namespace