Page 1 of 1

Realtime Candle

Posted: Mon Jun 11, 2007 4:45 pm
by 9640087
Hi

Is it possible to have a realtime price/time (minutes) series that dynamically updates a candle (O,H,L,C) as it is updated ? I will create the candle but need it to update as the new prices are added. Can the candle interval i.e. 5 mins / 10 mins also easily be changed.

Many thanks

Posted: Tue Jun 12, 2007 8:00 am
by 9348258
Hi JGM

Yes, it's possible. You can do it as below code:

Code: Select all

int candleIndex = 0 ; //First candle.

            candle1.HighValues[candleIndex] = 6;
            candle1.OpenValues[candleIndex] = 5;
            candle1.CloseValues[candleIndex] = 3;
            candle1.LowValues[candleIndex] = 1;
            tChart1.Invalidate(); //It's necessary to repaint the chart with new values.