I followed Mr Matheny advise about RT execution but have this problem (see attachment) of bleeding data.
I suppose it is because of every tick confirm that execution till it move to another price. The IB and Sound instructions are executing only once though.
I enclose the code:
// Exit and Alert us
if (nLastRawTime != getValue("rawtime", 0))
{
if (Do_IBAutomatedTrading )
{
trade.Buy(getSymbol(), Nbr_Contract, IBBroker.MARKET);
}
if (Do_Alert )
{
Alert.addToList(getSymbol(), AlertMessage, Color.black, Color.blue);
}
if (Do_Sounds )
{
Alert.playSound("c:\\Program Files\\ESIGNAL75\\Sounds\\ProfitTarget.wav");
}
BarCount += 1;
nLastRawTime = getValue("rawtime", 0);
// Reset the counters
strat_Target = 0;
strat_Stop = 0;
strat_EntryPrice = 0;
}
Thank you again.
Cheers
Andrei
I suppose it is because of every tick confirm that execution till it move to another price. The IB and Sound instructions are executing only once though.
I enclose the code:
// Exit and Alert us
if (nLastRawTime != getValue("rawtime", 0))
{
if (Do_IBAutomatedTrading )
{
trade.Buy(getSymbol(), Nbr_Contract, IBBroker.MARKET);
}
if (Do_Alert )
{
Alert.addToList(getSymbol(), AlertMessage, Color.black, Color.blue);
}
if (Do_Sounds )
{
Alert.playSound("c:\\Program Files\\ESIGNAL75\\Sounds\\ProfitTarget.wav");
}
BarCount += 1;
nLastRawTime = getValue("rawtime", 0);
// Reset the counters
strat_Target = 0;
strat_Stop = 0;
strat_EntryPrice = 0;
}
Thank you again.
Cheers
Andrei
Comment