Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

How to have stop loss and profit target on same order

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    How to have stop loss and profit target on same order

    Hello. I'm trying to put a stop loss and profit target on a single order. If I use the SetStopLoss() command, it orders with a stop loss only and I dont see how to add a profit target to that same order. Thank you.

    #2
    Hello kazisl, thanks for your post.

    We have the SetProfitTarget() method that will submit a profit target for entry orders:

    https://ninjatrader.com/support/help...ofittarget.htm

    Please let me know if I can assist any further.
    Chris L.NinjaTrader Customer Service

    Comment


      #3
      So if I use SetProfitTarget() and SetStopLoss(), doesn't that set 2 seperate orders?

      Comment


        #4
        Hello kazisl, thanks for your reply.

        That is correct. A limit order will be placed for SetProfitTarget and a stop market order will be used for SetStopLoss by default.

        Best regards.
        Chris L.NinjaTrader Customer Service

        Comment


          #5
          Would they automatically be OCO? Or is there something I need to do to make them OCO?

          Comment


            #6
            Hello kazisl, thanks for your reply.

            Yes, they will be OCO automatically. They will be associated with an entry order so if either the other protective order or the position is filled/closed the order will be canceled along with them.

            We also have a "DIY" version with advanced order handling techniques here:
            https://ninjatrader.com/support/help...and_onexec.htm

            Kind regards,
            -ChrisL
            Chris L.NinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by KennyK, 05-29-2017, 02:02 AM
            3 responses
            1,282 views
            0 likes
            Last Post NinjaTrader_Clayton  
            Started by AttiM, 02-14-2024, 05:20 PM
            11 responses
            184 views
            0 likes
            Last Post NinjaTrader_ChelseaB  
            Started by fernandobr, Today, 09:11 AM
            1 response
            3 views
            0 likes
            Last Post NinjaTrader_Erick  
            Started by timmbbo, Today, 08:59 AM
            1 response
            3 views
            0 likes
            Last Post NinjaTrader_ChelseaB  
            Started by itrader46, Today, 09:04 AM
            1 response
            6 views
            0 likes
            Last Post NinjaTrader_Clayton  
            Working...
            X