Events

EdgTrader raise various events when received you can perform tasks like sending order or plotting chart.

void OnTick()

Ontick event rasied when a new tick comes. It is raised in eBot. When recieved you do tasks related to trading like sending, canceling orders, checking market condition etc. This event runs on separate thread so can be blocked as long as needed.

void OnCalculate(int BarsCounted)

OnCalculate event rasied when a new tick comes. It is raised in eIndicator. When recieved you can plot indicator on chart. BarsCounted parameter gives number of bars on which indicator buffer need to recalculated at first its all bars. On formation of new candle BarsCounted reset to all bars count so whole buffer will be calculated again. This event runs on ui thread if takes too long will freeze whole trader.

void OnUninstalled()

OnUninstalled called when eBot or eIndicator is detached from chart.