PDA

View Full Version : Coloring bars


max1ci6
01-10-2008, 10:26 AM
Dear Sirs

I have a custom indicator which paints all the session bars every 2 sessions (see attached), it uses an integer variable which switches between 0 and 1 at each new session first bar .
I used this to paint the bars :
if (value1 == 0)
{
BarColor=Color.Maroon;
}

How can code it so to have the color for the bars as input in the General Section of the indicator ?

Rgds.

Massimo

NinjaTrader_Ray
01-10-2008, 10:49 AM
See the indicator VolumeZones NinjaScript code.

See the variables section as well as the Properties section paying special attention to the properties that serialize color.