Page 1 of 1

ZIG function

Posted: Tue Apr 12, 2011 7:03 am
by 15656007
Hello,
Is there a ZIG function in your TeeChart Pro ActiveX product?
Thanks!
Best Regards,
Candy

Re: ZIG function

Posted: Tue Apr 12, 2011 9:10 am
by 10050769
Hello Candy,

Could you confirm us if ZIG function it is the same if ZIG-ZAG function? And also, could you explain step to step what you want do exactly because ZIG function isn't in TeeChart Activex, but it can be possible to find a solution that behaves as Zig function.

Thanks,

Re: ZIG function

Posted: Wed Apr 13, 2011 8:18 am
by 15656007
Hello,
Thank for your reply.
I want to get the value of the peak or crest of a wave . Is there any other function I can use?

The other question is: Is there a mouse click event in the TeeChart ActiveX Control , and How could I get which area is clicked?
Thanks!
Best Regards,
Candy

Re: ZIG function

Posted: Wed Apr 13, 2011 3:41 pm
by yeray
Hello Candy,
Candy wrote:I want to get the value of the peak or crest of a wave . Is there any other function I can use?
You could check the Series' YValues.Maximum property. For example:

Code: Select all

Caption = Str$(TChart1.Series(0).YValues.Maximum)
If you want to mark the maximum value with an horizontal line, you could use a ColorLine as follows:

Code: Select all

Private Sub Form_Load()  
  TChart1.Aspect.View3D = False
  
  TChart1.AddSeries scLine
  TChart1.Series(0).FillSampleValues
  
  TChart1.Tools.Add tcColorLine
  TChart1.Tools.Items(0).asColorLine.Pen.Color = vbRed
  TChart1.Tools.Items(0).asColorLine.Axis = TChart1.Axis.Left
  TChart1.Tools.Items(0).asColorLine.Value = TChart1.Series(0).YValues.Maximum
End Sub
Candy wrote:Is there a mouse click event in the TeeChart ActiveX Control , and How could I get which area is clicked?
There are different events for some parts of the chart. There is an OnClickSeries event, an OnClickLegend event, an OnClickAxis event, an OnClickBackground event and a more general OnClick event.
You can also combine this events (or also the OnMouseDown/OnMouseUp event) with the Clicked method available on series, axis,... depending on what you are exactly trying to achieve.