Shut down an indicator via code? is it possible

Questions about MultiCharts and user contributed studies.
arjfca
Posts: 1292
Joined: 23 Nov 2010
Has thanked: 725 times
Been thanked: 223 times

Shut down an indicator via code? is it possible

Postby arjfca » 21 Aug 2013

Hello

Is there a way to cancell all plotted info on a chart from the code. I would like to have a cleaner chart when I look at my chart using a narrow bar spacing.

I'm able to read the bar spacing using getappinfo(aiBarSpacing). I see that the value is modified whenever I use the icone on my bar to increase or decrease the spacing. But I did not succeed to cancel the already plotted info yet.

The only way that i found is by unselecting the indicator.

Martin

Code exemple:

Code: Select all

Barspacing = getappinfo(aiBarSpacing) ;
If barspacing <> Barspacing_ex then begin
Barspacing_ex = Barspacing;
Arrowstyle_show = 1;
Print ( barspacing, " ", Barspacing_ex);
end
else begin
Arrowstyle_show = arrowstyle;
end;
if barspacing >=1.3 then begin
Attachments
Clean.png
(30.37 KiB) Downloaded 527 times
messy.png
(61.58 KiB) Downloaded 532 times

User avatar
TJ
Posts: 7742
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2222 times

Re: Shut down an indicator via code? is it possible

Postby TJ » 21 Aug 2013

right click on chart,

select Remove All Drawings.


if you want your drawings back,
use "Jump" to go back one bar,
then click on the "Terminate Playback" icon.
MultiCharts will redraw all objects.

arjfca
Posts: 1292
Joined: 23 Nov 2010
Has thanked: 725 times
Been thanked: 223 times

Re: Shut down an indicator via code? is it possible

Postby arjfca » 21 Aug 2013

right click on chart,

select Remove All Drawings.


if you want your drawings back,
use "Jump" to go back one bar,
then click on the "Terminate Playback" icon.
MultiCharts will redraw all objects.
I like your idea.

But you know me,... I like to automatise all steps...
It would be interesting if I was able to cancell all drawing whenever I sqeeze the chart.

A good evening to all
Martin

User avatar
TJ
Posts: 7742
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2222 times

Re: Shut down an indicator via code? is it possible

Postby TJ » 21 Aug 2013

::
It would be interesting if I was able to cancell all drawing whenever I sqeeze the chart.
You sure can... if there is a will, there is a way.

User avatar
piranhaxp
Posts: 241
Joined: 18 Oct 2005
Has thanked: 4 times
Been thanked: 30 times

Re: Shut down an indicator via code? is it possible

Postby piranhaxp » 22 Aug 2013

I would like to have a cleaner chart when I look at my chart
MAYBE YOU SHOULD USE MORE TRANSPARENCY TOOLS FOR BETTER VISUALITY .... :)

User avatar
Henry MultiСharts
Posts: 9165
Joined: 25 Aug 2011
Has thanked: 1264 times
Been thanked: 2957 times

Re: Shut down an indicator via code? is it possible

Postby Henry MultiСharts » 26 Aug 2013

Hello Martin,

Unfortunately there is no way to turn off an indicator via the code at the moment.
Please submit a feature request to the Project Management of our web site so other users can vote for it: https://www.multicharts.com/pm/


Return to “MultiCharts”