After order filled, trigger a stop loss order
Author: gchudublin
Creation Date: 2/27/2018 4:15 PM
profile picture

gchudublin

#1
Would you please let me know if you have this code on site already? I need to have this code to trade, since Fidelity Active Trader Pro can not do this quickly when I place a trade.
profile picture

Eugene

#2
How quick is "quickly"? With Wealth-Lab you can place an order on the next bar.
profile picture

gchudublin

#3
Yes, next bar. Need to place a bracket order with sell limit and stop. So when I place an order and order filled will trigger this order with fix upper sell limit and stop loss limit.

Thanks

Greg
profile picture

Eugene

#4
Greg, you can quickly get some sample code for bracket orders by generating it yourself using the Rule Wizard. Strike Ctrl-Shift-R, add a Buy order, then pick "Long Exit at Profit Target with fixed Stop Loss" (or Trailing Stop) from the Bracketed Exits group.

Same-bar exits are also possible in auto trading if you activate "Allow Same Bar Exits for Auto-Trading" in Wealth-Lab's Preferences > Trading. For this you need to set RiskStopLevel and AutoProfitLevel as instructs the Wealth-Lab User Guide (Preferences > Trading) and the QuickRef.
profile picture

Cone

#5
For those same-bar exits to work, you must have an Auto-Trade entitlement at Fidelity. Note that the option is "Allow Same Bar Exits for Auto-Trading".
This website uses cookies to improve your experience. We'll assume you're ok with that, but you can opt-out if you wish (Read more).