I went into this problem recently.
I use Trade.PositionClose from the library to close a position. Looking at its code, it uses TRADE_ACTION_CLOSE_BY, which means it is closing by opening a trade in the opposite direction.
Problem is that on a pair, trade is disabled. Info says that this symbol is "close only". I could close the position manually but using Trade.PositionClose didn't work. Error was "trade is disabled".
Thanks for your help.