Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Using SCript Wizard To Create Multilple Order Entries with Different Price

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

    Using SCript Wizard To Create Multilple Order Entries with Different Price

    Can it be done in the Wizard?

    I'm looking for a script that would do the following when run:

    -enter 2 Long Limit order below the Bid
    -enter 2 Long StopLimit order above the Ask price

    It is sound simple but I can only get the script to enter one entry at a time but not all 4.

    Thanks

    #2
    Tranbo, please try setting Entries Per Direction to a higher value.
    Attached Files
    AustinNinjaTrader Customer Service

    Comment


      #3
      The "Entries Per Direction" doesn't do it. I set it to 4 it gave me 4 entries of the same price position.

      How do I get 4 entries for 4 limit order with 4 different price?

      Anything wrong with the condition set below?

      // Condition set 1
      if (OpenLongPosition == true)
      {
      EnterLong(DefaultQuantity, "");
      EnterLongLimit(DefaultQuantity, GetCurrentBid() + -10 * TickSize, "");
      EnterLongLimit(DefaultQuantity, GetCurrentBid() + -20 * TickSize, "");
      EnterLongStop(DefaultQuantity, GetCurrentAsk() + 10 * TickSize, "");
      EnterLongStop(DefaultQuantity, GetCurrentAsk() + 20 * TickSize, "");
      }

      Comment


        #4
        Please try with unique entry handling and per direction to 4, then use those code lines to add a unique name for each order -

        Code:
         
        EnterLongLimit(DefaultQuantity, GetCurrentBid() - 10 * TickSize, "1");
        EnterLongLimit(DefaultQuantity, GetCurrentBid() - 20 * TickSize, "2");
        EnterLongStop(DefaultQuantity, GetCurrentAsk() + 10 * TickSize, "3");
        EnterLongStop(DefaultQuantity, GetCurrentAsk() + 20 * TickSize, "4");

        Comment


          #5
          One more question on this topic. I noticed the entry that work keep changing due to the bid/price changing.

          What is the name or value of the Open Session Price? I'm looking for something that is static once the session open.

          Will keep you posted once I get this to work.

          Thank-You!

          Comment


            #6
            Correct, those orders expire after one bar per default and then would be resubmitted if your condition is still 'true'.

            For the session open as defined by your session begin / end times (chart properties) you can use the CurrentDayOHL indicator accessing the CurrentOpen plot -


            Comment


              #7
              I got it working now. But it not very useful LOL

              Thanks

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by argusthome, 03-08-2026, 10:06 AM
              0 responses
              88 views
              0 likes
              Last Post argusthome  
              Started by NabilKhattabi, 03-06-2026, 11:18 AM
              0 responses
              48 views
              0 likes
              Last Post NabilKhattabi  
              Started by Deep42, 03-06-2026, 12:28 AM
              0 responses
              30 views
              0 likes
              Last Post Deep42
              by Deep42
               
              Started by TheRealMorford, 03-05-2026, 06:15 PM
              0 responses
              34 views
              0 likes
              Last Post TheRealMorford  
              Started by Mindset, 02-28-2026, 06:16 AM
              0 responses
              68 views
              0 likes
              Last Post Mindset
              by Mindset
               
              Working...
              X