Detecting if a stop exists

Questions about MultiCharts and user contributed studies.
stockmacd
Posts: 23
Joined: 28 Feb 2007

Detecting if a stop exists

Postby stockmacd » 27 Oct 2009

One can detect whether there's an open position by using MarketPosition=1, but is there a way to detect if there is a STOP ?

For Autotrading, I have a trailing stop loss that's calculated with IntraBarOrderGeneration = true, so within 1 bar there could be multiple stops being sent to TWS. I want only want to keep the highest stop.

Another option would be to cancel any existing stop when a new stop is sent to TWS.

Return to “MultiCharts”