You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
This coding was to eliminate only pending buy and sell stop orders. It unfortunately is deleting both the pending buy and sell stop orders, but also the orders that are active and in play. How can I change this to only eliminate the pending and not the active buy and sell stops that are in play? Your ideas will be greatly appreciated.
Dave 77, TGIF
Houston, TX
For cnt=1 to TotalTrades
{
mode=OrderValue(cnt,VAL_TYPE);
If mode>OP_SELL then
{
If (Minute>58)then // Delete pending Sell Stops.
{
DeleteOrder(OrderValue(cnt,VAL_TICKET),Cyan);
Exit;
};
};
If mode>OP_BUY then
{
If (Minute>58)then // Delete pending Buy Stops.
{
DeleteOrder(OrderValue(cnt,VAL_TICKET),Cyan);
Exit;
};
};