Closing only a part of a existing position

 

Hi,

I can't find the possibility to close only the half of my position.

With OrderModify() I can only modify the hole position

 
Use OrderSelect() then use OrderClose() with OrderLots()/2 . . . . . I reckon, I've never used it.
 

OrderLots()/2 will not work. The remainder must be a multiple of lotStep.

From my code: https://www.mql5.com/en/forum/137652