How to know when a stoploss was hit.

 

Hi all,

I'm looking for a piece of code that finds out if a stoploss was hit so my EA can take action.

Alternatively: How can know the price at which the order closed?

The real closing price; not the prefered one.

Reason: