Visual Order for an Indicator that plots a Vertical Line  [SOLVED]

Questions about MultiCharts and user contributed studies.
Linden
Posts: 2
Joined: Aug 31 2012

Sep 03 2012

Hello,

On MC 8, 32 bit, Range bars, how do you program a vertical Line to be behind price bars? My rudimentary example below for GOLD open/close of pit times?

Problems:
1. If no bar forms during the 'zone' then no vertical line.
2. Sometimes vertical line displays then no vertical line then some more. Why?

Thanks in advance for any input.

Linden
Pict of vertical lines.bmp
(800.85 KiB) Downloaded 322 times
Example:

Input : colorB(darkgreen),colorE(red), size(1);
//Begin Time 5 minutes "Zone"
If Time_s > 080000 and Time_s < 082000 then begin
value1=tl_new_s(date,time_s,l,date,time_s,h);
tl_setcolor(value1,colorB);
tl_setstyle(value1,Tool_Dotted);
tl_setsize(value1,size);
tl_setextleft(value1,true);
tl_setextright(value1,true);
end;
//End Time 1/2 hour "Zone"
If Time_s > 130000 and Time_s < 133000 then begin
value1=tl_new_s(date,time_s,l,date,time_s,h);
tl_setcolor(value1,colorE);
tl_setstyle(value1,Tool_Dotted);
tl_setsize(value1,size);
tl_setextleft(value1,true);
tl_setextright(value1,true);
end;

User avatar
TJ
Posts: 7765
Joined: Aug 29 2006
Location: Global Citizen
Has thanked: 1036 times
Been thanked: 2232 times

Sep 03 2012

Hello,

On MC 8, 32 bit, Range bars, how do you program a vertical Line to be behind price bars? My rudimentary example below for GOLD open/close of pit times?

Problems:
1. If no bar forms during the 'zone' then no vertical line.
2. Sometimes vertical line displays then no vertical line then some more. Why?

Thanks in advance for any input.

Linden
Pict of vertical lines.bmp
Example:

Input : colorB(darkgreen),colorE(red), size(1);
//Begin Time 5 minutes "Zone"
If Time_s > 080000 and Time_s < 082000 then begin
value1=tl_new_s(date,time_s,l,date,time_s,h);
tl_setcolor(value1,colorB);
tl_setstyle(value1,Tool_Dotted);
tl_setsize(value1,size);
tl_setextleft(value1,true);
tl_setextright(value1,true);
end;
//End Time 1/2 hour "Zone"
If Time_s > 130000 and Time_s < 133000 then begin
value1=tl_new_s(date,time_s,l,date,time_s,h);
tl_setcolor(value1,colorE);
tl_setstyle(value1,Tool_Dotted);
tl_setsize(value1,size);
tl_setextleft(value1,true);
tl_setextright(value1,true);
end;
you can try the plot method instead.

viewtopic.php?f=1&t=10823

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

Sep 05 2012

Hello Linden,

Trendlines cannot be plotted behind the data series. You need to use Plot per TS's suggestion to be able to control the visual order of the chart.