BcLib update - New powerful trading functions
This BcLib issue adds new trading functions:
- ReliableModifyTakeProfit() and ReliableModifyStopLoss(), which attempt to place and repair the TP and SL levels , by moving them up or down (take profit, for buys and sells) , down or up (stop loss, for buys and sells) in order to avoid ERR_INVALID_STOPS, which is the only error handled by these functions. The fast functions ModifyTakeProfit() and ModifyStopLoss(), older, simply attempt to do this once without handling any error.
- ReliableOrderPlace(), which is an upgrade of the ReliableOrderSend() . The difference is that SL and TP are integers , given by the user in pips. ReliableOrderPlace() calls ReliableOrderSend() to manage placing of the order without SL and TP, then it uses ReliableModifyTakeProfit() and ReliableModifyStopLoss to set TP and SL levels. This is why, if any errors appear in the log, they are reported by ReliableOrderSend(), not by ReliableOrderPlace().
3 Comentarii
Comentarii Recomandate