Interactive draw tool - is this possible?

Questions about MultiCharts .NET and user contributed studies.
MidKnight
Posts: 343
Joined: 12 Aug 2012
Has thanked: 123 times
Been thanked: 56 times

Interactive draw tool - is this possible?

Postby MidKnight » 14 Nov 2013

Hi there,

I am considering the idea of having a tool that lets you click on 2 bars of your chart and it will perform a calculation on all bars within the selection. Is this possible for us to code? I wouldn't even know where to start.....

With kind regards,
MK

User avatar
Henry MultiСharts
Posts: 9092
Joined: 25 Aug 2011
Has thanked: 1258 times
Been thanked: 2923 times

Re: Interactive draw tool - is this possible?

Postby Henry MultiСharts » 14 Nov 2013

Hello MidKnight,

That is possible to implement such code. There are multiple ways that come to my mind:
1) Use OnMouseEvent Method that will return the bar number into the code to perform further calculation.
2) Use drawings to determine start and end points for calculation.
You can also create a button that will start the calculation only after you press it.

MidKnight
Posts: 343
Joined: 12 Aug 2012
Has thanked: 123 times
Been thanked: 56 times

Re: Interactive draw tool - is this possible?

Postby MidKnight » 14 Nov 2013

Good to hear Henry and thanks for the suggestions. Using a drawing is probably the way I would like to go - is there any example code of doing custom drawings based on user interaction?

With thanks,
MK

User avatar
Henry MultiСharts
Posts: 9092
Joined: 25 Aug 2011
Has thanked: 1258 times
Been thanked: 2923 times

Re: Interactive draw tool - is this possible?

Postby Henry MultiСharts » 15 Nov 2013

Good to hear Henry and thanks for the suggestions. Using a drawing is probably the way I would like to go - is there any example code of doing custom drawings based on user interaction?

With thanks,
MK
The algorithm is like that - place the drawing manually on the chart, then read the drawing values from the code. Unfortunately I do not have a sample code at hand for that.


Return to “MultiCharts .NET”