I want to add a condition for an exit that will include something along the lines of the Realized Profit on that specific trade.
Background on my strategy:
The strategy will buy X number of contracts and sell half if the price moves 16 ticks in my favor.
Once it hits 16 ticks, the strategy sells half of the contracts and lets the others run.
It trades on the 15, 30, and 60 timeframes.
I have specific entries for each, "15Long" or "15Short", etc
I originally had language based on Position Quantity but I ran into issues if I got a partial fill. I am thinking that something along the lines of
if RealiedProfit of "15Long" > $0
{
Do Something
}
I just don't know what the code would be for the part with the red text above. And it would have to reset after the "15Long" trade closes so the next time "15Long" occurs, it doesn't register there being profit from the last trade.
Could you help me out please?
Thank you,
Nick
Comment