Forum

Using the MetaTrader 5 Python library, How can i set take profit orders for open positions that execute like limit orders instead of market orders

As the title says i want to take profit on open positions that execute like limit orders to avoid crossing the spread or incurring slippage. TRADE_ACTION_SLTP allows you to set a take profit price that the order is execute at but the actual execution acts like a market order. Here is my current