I'm trying to draw vertical lines at various times on chart on a single day with the following code. There is no error, but the vertical lines are not showing up... This is so frustrating...
Please help.
if ((ToDay(Time[0]) == 20150915))
{
if ((ToTime(Time[0]) == 001318))
DrawVerticalLine("orange" + CurrentBar, 0, Color.Orange);
if ((ToTime(Time[0]) == 011206))
DrawVerticalLine("black" + CurrentBar, 0, Color.Black);
if ((ToTime(Time[0]) == 021055))
DrawVerticalLine("orange" + CurrentBar, 0, Color.Orange);
if ((ToTime(Time[0]) == 030943))
DrawVerticalLine("red" + CurrentBar, 0, Color.Red);
if ((ToTime(Time[0]) == 040831))
DrawVerticalLine("red" + CurrentBar, 0, Color.Red);
if ((ToTime(Time[0]) == 050719))
DrawVerticalLine("blue" + CurrentBar, 0, Color.Blue);
if ((ToTime(Time[0]) == 060607))
DrawVerticalLine("green" + CurrentBar, 0, Color.Green);
if ((ToTime(Time[0]) == 070715))
DrawVerticalLine("orange" + CurrentBar, 0, Color.Orange);
if ((ToTime(Time[0]) == 080823))
DrawVerticalLine("black" + CurrentBar, 0, Color.Black);
if ((ToTime(Time[0]) == 090930))
DrawVerticalLine("orange" + CurrentBar, 0, Color.Orange);
if ((ToTime(Time[0]) == 101038))
DrawVerticalLine("red" + CurrentBar, 0, Color.Red);
if ((ToTime(Time[0]) == 111146))
DrawVerticalLine("red" + CurrentBar, 0, Color.Red);
if ((ToTime(Time[0]) == 121253))
DrawVerticalLine("blue" + CurrentBar, 0, Color.Blue);
if ((ToTime(Time[0]) == 131401))
DrawVerticalLine("green" + CurrentBar, 0, Color.Green);
if ((ToTime(Time[0]) == 141509))
DrawVerticalLine("orange" + CurrentBar, 0, Color.Orange);
if ((ToTime(Time[0]) == 151616))
DrawVerticalLine("black" + CurrentBar, 0, Color.Black);
if ((ToTime(Time[0]) == 161724))
DrawVerticalLine("orange" + CurrentBar, 0, Color.Orange);
if ((ToTime(Time[0]) == 171831))
DrawVerticalLine("red" + CurrentBar, 0, Color.Red);
if ((ToTime(Time[0]) == 181939))
DrawVerticalLine("red" + CurrentBar, 0, Color.Red);
if ((ToTime(Time[0]) == 191832))
DrawVerticalLine("blue" + CurrentBar, 0, Color.Blue);
if ((ToTime(Time[0]) == 201725))
DrawVerticalLine("green" + CurrentBar, 0, Color.Green);
if ((ToTime(Time[0]) == 211618))
DrawVerticalLine("orange" + CurrentBar, 0, Color.Orange);
if ((ToTime(Time[0]) == 221511))
DrawVerticalLine("black" + CurrentBar, 0, Color.Black);
if ((ToTime(Time[0]) == 231401))
DrawVerticalLine("orange" + CurrentBar, 0, Color.Orange);
}
else
return;

Awesome!!
Comment