• #3302
      Mihail
      Basic

      When using the script Signal Trigger with Multiple Positions, an error occurs on Binance:
      WARNING: Order has failed to execute. Reason: Parameter ‘reduceOnly’ sent when not required. (Exchange error code: -1106)

      Tell me please, I just need to remove the only parameter in the code or replace it with another one, because is it really not possible to place orders with reduce only on binance in the web version?
      Here is the piece of code:

      if allowshort then
      if And(ShortOID == ”, shortsignal == SignalShort, checkdelta(false, Max(LastShortPrice(), GetPositionEnterPrice(ShortPosId)), spreadk)) then
      params.positionId = ShortPosId; params.note = ‘Go Short – ‘..ShortPosId; params.reduceOnly = false
      CC_getOID(false, k, PlaceGoShortOrder(getprice(false, false, k), TradeAmount(), params))
      elseif And(allowshortx, ShortOID == ”, shortsignal == SignalExitShort, checkdelta(true, Min(LastExitShortPrice(), GetPositionEnterPrice(ShortPosId)), spreadk)) then
      params.positionId = ShortPosId; params.note = ‘Exit Short – ‘..ShortPosId; params.reduceOnly = true
      CC_getOID(false, k, PlaceExitShortOrder(getprice(false, true, k), TradeAmount()/xdivs, params))
      end
      end
      if allowlong then
      if And(LongOID == ”, longsignal == SignalLong, checkdelta(true, Min(LastLongPrice(), GetPositionEnterPrice(LongPosId)), spreadk)) then
      params.positionId = LongPosId; params.note = ‘Go Long – ‘..LongPosId; params.reduceOnly = false
      CC_getOID(true, k, PlaceGoLongOrder(getprice(true, false, k), TradeAmount(), params))
      elseif And(allowlongx, LongOID == ”, longsignal == SignalExitLong, checkdelta(false, Max(LastExitLongPrice(), GetPositionEnterPrice(LongPosId)), spreadk)) then
      params.positionId = LongPosId; params.note = ‘Exit Long – ‘..LongPosId; params.reduceOnly = true
      CC_getOID(true, k, PlaceExitLongOrder(getprice(true, true, k), TradeAmount()/xdivl, params))
      end

    • #3301
      Mihail
      Basic

      Nice, need cheked

Viewing 1 reply thread

Unlock your crypto trading potential

Create a free account and enjoy everything we have to offer.

Join for Free