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

Set Stop Loss at the low of the signal bar

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

    Set Stop Loss at the low of the signal bar

    Hey folks
    I am now trying to automate one of my strategies. I usually set the stop loss one tick below the signal bar.
    I was using the following, but it doesn't work:
    SetStopLoss("Entry", CalculationMode.Price, Low[0], false);
    This is how i open my positions:
    EnterLongStop(DefaultQuantity, High[0], "Entry");
    Thanks in advance.

    #2
    Originally posted by jzag456 View Post
    Hey folks
    I am now trying to automate one of my strategies. I usually set the stop loss one tick below the signal bar.
    I was using the following, but it doesn't work:
    SetStopLoss("Entry", CalculationMode.Price, Low[0], false);
    This is how i open my positions:
    EnterLongStop(DefaultQuantity, High[0], "Entry");
    Thanks in advance.
    Show where and how you are using those lines.

    Comment


      #3
      The Set Stop Loss and Calculation Mode Price were generated by the strategy wizard. I just added "Low (0).

      Comment


        #4
        thats some useless information. no offence

        lets try it by asking what went wrong. did u get an error? what error.

        did he place the stop wrong

        no stop at all?


        u have to give us a bit here if you want help. bc from a coding standpoint those 2 lines you posted are perfectly fine. so it has so be something else in your code thats not right.

        Comment


          #5
          I didnt receive any error. All positions were closed at the end of the day. So there was no stop loss set by the system.
          Everything was created by the Strategy Wizard.

          Comment


            #6
            Hello jzag456,

            Thank you for writing in. In order for us to investigate further, please follow the instructions contained in this help guide document to export your strategy: http://ninjatrader.com/support/helpG...ightsub=export
            Then navigate to your (My) Documents\NinjaTrader 7\bin\Custom\ExportNinjaScript folder and either attach your exported strategy to your forum post or email it to platformsupport[AT]ninjatrader[DOT]com with the subject line: "ATTN Michael M: http://www.ninjatrader.com/support/forum/showthread.php?t=80077".

            Thank you in advance.
            Michael M.NinjaTrader Quality Assurance

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by Taddypole, 04-26-2024, 02:47 PM
            1 response
            12 views
            0 likes
            Last Post NinjaTrader_Eduardo  
            Started by futtrader, 04-21-2024, 01:50 AM
            6 responses
            58 views
            0 likes
            Last Post futtrader  
            Started by sgordet, Today, 11:48 AM
            0 responses
            4 views
            0 likes
            Last Post sgordet
            by sgordet
             
            Started by Trader146, Today, 11:41 AM
            0 responses
            5 views
            0 likes
            Last Post Trader146  
            Started by jpapa, 04-23-2024, 07:22 AM
            2 responses
            20 views
            0 likes
            Last Post rene69851  
            Working...
            X