Page 1 of 1

OnColorLineToolDragLine event Not available in Teechart .Net

Posted: Thu Jan 22, 2015 5:01 am
by 16071129
I am not getting OnColorLineToolDragLine event in Teechart .Net version.
This is present in Teechart ActiveX version.
Kindly help me to find out the alternative solution.

Re: OnColorLineToolDragLine event Not available in Teechart .Net

Posted: Thu Jan 22, 2015 10:55 am
by narcis
Hello Quant,

Here it is:

Code: Select all

  public partial class Form1 : Form
  {
    public Form1()
    {
      InitializeComponent();
      InitializeChart();
    }

    private Steema.TeeChart.Tools.ColorLine colorLine1;

    private void InitializeChart()
    {
      tChart1.Series.Add(new Steema.TeeChart.Styles.Line()).FillSampleValues();

      colorLine1 = new Steema.TeeChart.Tools.ColorLine(tChart1.Chart);
      colorLine1.Axis = tChart1.Axes.Bottom;
      colorLine1.Value = 5;
      colorLine1.DragLine += colorLine1_DragLine;
    }

    void colorLine1_DragLine(object sender, EventArgs e)
    {
      tChart1.Header.Text = colorLine1.Value.ToString();
    } 
  }

Re: OnColorLineToolDragLine event Not available in Teechart .Net

Posted: Fri Jan 23, 2015 4:55 am
by 16071129
it worked thank you