Fibonanci Retracement Tool
Fibonanci Retracement Tool
Hi All,
There is no event for FibonanciTool (other than Disposed) present in TeeChart .Net.
We need to select already drawn FibonanciTool using code. How can we achieve the same?
There is no event for FibonanciTool (other than Disposed) present in TeeChart .Net.
We need to select already drawn FibonanciTool using code. How can we achieve the same?
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Re: Fibonanci Retracement Tool
Hello Quant,
Yes, you are right. I have added your request to bugzilla (#1174). Does the bug description fit your needs?
Thanks for your collaboration.
Yes, you are right. I have added your request to bugzilla (#1174). Does the bug description fit your needs?
Thanks for your collaboration.
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Fibonanci Retracement Tool
i am using latest version 4.1.2015.08061 but still not getting any event.
-
- Guru
- Posts: 1603
- Joined: Fri Nov 15, 2002 12:00 am
Re: Fibonanci Retracement Tool
Hello,
That's because no event was added; however, a Clicked method was added which can be used like this:Quant wrote:i am using latest version 4.1.2015.08061 but still not getting any event.
Code: Select all
FibonacciTool tool;
private void InitializeChart()
{
tChart1.Aspect.View3D = false;
tool = new FibonacciTool(tChart1.Chart);
Candle candle = new Candle(tChart1.Chart);
candle.FillSampleValues(40);
tool.StartX = candle.DateValues[0];
tool.StartY = candle.CloseValues[0];
tool.EndX = candle.DateValues[10];
tool.EndY = candle.CloseValues[10];
tool.Series = candle;
tChart1.MouseDown += TChart1_MouseDown;
}
private void TChart1_MouseDown(object sender, MouseEventArgs e)
{
tChart1.Header.Text = "FibonacciTool clicked " + tool.Clicked(e.X, e.Y);
}
Best Regards,
Christopher Ireland / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Fibonanci Retracement Tool
by this way selection can not be highlighted.
I want selector tool to select fibonacci. same as we are selecting rectangle or line.
I want selector tool to select fibonacci. same as we are selecting rectangle or line.
-
- Guru
- Posts: 1603
- Joined: Fri Nov 15, 2002 12:00 am
Re: Fibonanci Retracement Tool
You could highlight the tool by changing the Pen colors, e.g.Quant wrote:by this way selection can not be highlighted.
Code: Select all
private void TChart1_MouseDown(object sender, MouseEventArgs e)
{
bool clicked = tool.Clicked(e.X, e.Y);
for (int i = 0; i < tool.Levels.Count; i++)
{
tool.Levels[i].Pen.Color = clicked ? Color.Fuchsia : Color.Black;
}
tool.TrendPen.Color = clicked ? Color.Fuchsia : Color.Black;
}
Best Regards,
Christopher Ireland / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Fibonanci Retracement Tool
we dont want this work around. we want same way as we select line or rectangle tool.
-
- Guru
- Posts: 1603
- Joined: Fri Nov 15, 2002 12:00 am
Re: Fibonanci Retracement Tool
How do you select a line or a rectangle tool?Quant wrote:we dont want this work around. we want same way as we select line or rectangle tool.
Best Regards,
Christopher Ireland / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Fibonanci Retracement Tool
with selector tool
-
- Guru
- Posts: 1603
- Joined: Fri Nov 15, 2002 12:00 am
Re: Fibonanci Retracement Tool
I see, thank you. This is quite a different request to the origin request in this thread, and as such has been added to our issue tracking software with id=1325.Quant wrote:with selector tool
Best Regards,
Christopher Ireland / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Re: Fibonanci Retracement Tool
Hello,
Selector marks can be client coded on the Fibonacci Trendline in this way:
The Arcs or alternatively drawstyled lines can also have selector marks applied to them, it requires a little more work to extract the values from the Fibonacci class.
Regards,
Marc Meumann
Selector marks can be client coded on the Fibonacci Trendline in this way:
Code: Select all
bool isFiboClicked = false;
private void TChart1_MouseDown(object sender, MouseEventArgs e)
{
if (fibonacciTool1.Clicked(e.X, e.Y))
isFiboClicked = true;
else
isFiboClicked = false;
tChart1.Invalidate();
}
private void tChart1_AfterDraw(object sender, Drawing.Graphics3D g)
{
if (isFiboClicked)
{
int startX = tChart1.Axes.Bottom.CalcPosValue(fibonacciTool1.StartX);
int startY = tChart1.Axes.Left.CalcPosValue(fibonacciTool1.StartY);
int endX = tChart1.Axes.Bottom.CalcPosValue(fibonacciTool1.EndX);
int endY = tChart1.Axes.Left.CalcPosValue(fibonacciTool1.EndY);
g.Brush.Solid = true;
g.Brush.Color = Color.Black;
g.Rectangle(startX - 4, startY - 4, startX + 4, startY + 4);
g.Rectangle(endX - 4, endY - 4, endX + 4, endY + 4);
}
}
Regards,
Marc Meumann
Steema Support