DETERMINING WHAT POSITION WAS CLOSED, AND OPENING A NEW ONE ACCORDINGLY... IS IT POSSIBLE?

 

Hey folks, is there "annnyyy" script which can detect the following things:

1. The time when an open position is closed (for example, it should keep checking every second, 10 seconds, 1 minute, etc., etc., and trigger the desired event as soon as an open position closes due to SL or TP).

2. It should also be able to know what type of position it was, which got closed last (i.e., whether BUY or SELL)

thanks a lot

xnasir

Reason: