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

Problems executing orders

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

    Problems executing orders

    Hi, I have a ninja account connected to Rithmic, when I try to use the EnterLong or EnterShort in RealTime it works, but when I am in State.Historical and I use EnterLong or EnterShort the method doesn't work, that is to say it does nothing, it does not generate any error, it just does nothing, can you help me with this?.

    #2
    Hello 7robert,

    Please test the SampleMACrossover included with NinjaTrader. Do the market orders from this show in the Strategy Performance window once the strategy is enabled?

    In your script enable TraceOrders in State.Configure, open the NinjaScript Output window, then reload the script. Are there messages about ignored orders in the output window?
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Hi, I followed the steps you gave me and I have many lines in the Output with this:

      06/27/2023 5:01:00 Strategy 'Sample MA crossover/298755309': Entered internal method SubmitOrderManaged() on 06/27/2023 5:01:00: BarsInProgress=0 Action=SellShort OrderType=Market Quantity=1 LimitPrice=0 StopPrice=0 SignalName='' FromEntrySignal=''

      06/27/2023 5:01:00 Strategy 'Sample MA crossover/298755309': Ignored SubmitOrderManaged() method on 06/27/2023 5:01:00: BarsInProgress=0 Action=SellShort OrderType=Market Quantity=1 LimitPrice=0 StopPrice=0 SignalName='Sell Short' FromEntrySignal='' Reason='Exceeded input signal limit based on EntryHandling and EntriesPerDirection properties'​

      Comment


        #4
        Hello 7robert,

        The 'Ignored SubmitOrderManaged()' 'Exceeded input signal limit based on EntryHandling and EntriesPerDirection properties' means you have already placed an order in the position.

        Either increase EntriesPerDirection to all new orders to increase the position, or use the the UniqueEntries entry handling and give each new order a new unique signal name.

        This is discussed in the 'Automate Your Trading with NinjaTrader's Strategy Builder' training video.
        NinjaTrader's Strategy Builder empowers traders of all levels with point-and-click automated trading strategy development. Create your own advanced automated...

        Chelsea B.NinjaTrader Customer Service

        Comment


          #5
          Hi, I mean I have a strategy and I use the EnterLong method but in Realtime state which works but if it is disabled and subsequently enable the strategy we need to enter a historical position in order to recover the position or simulate the recovery, in this case I am using EnterLong when I enable the strategy but in historical state and I am using the same signal name, I have EntryHandling = EntryHandling.AllEntries; and EntriesPerDirection I increased it to 20, but the same thing keeps happening, previously I used this to recover but now it doesn't seem to work.

          Thanks for the help.

          Comment


            #6
            Hello 7robert,

            You have stated you increased EntriesPerDirection to 20. Did you do this in State.Configure? (If this is State.SetDefaults may I confirm you have removed the instance and added a new instance to pull the defaults?)

            Are there are already 20 entries orders submitted making up the position?
            Chelsea B.NinjaTrader Customer Service

            Comment


              #7
              Hello, I had to restart the instance and I made a mistake I said 20 entries per direction, but it was 2, so I think the problem is solved.

              Thank you very much.​

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by Segwin, 05-07-2018, 02:15 PM
              14 responses
              1,789 views
              0 likes
              Last Post aligator  
              Started by Jimmyk, 01-26-2018, 05:19 AM
              6 responses
              837 views
              0 likes
              Last Post emuns
              by emuns
               
              Started by jxs_xrj, 01-12-2020, 09:49 AM
              6 responses
              3,293 views
              1 like
              Last Post jgualdronc  
              Started by Touch-Ups, Today, 10:36 AM
              0 responses
              13 views
              0 likes
              Last Post Touch-Ups  
              Started by geddyisodin, 04-25-2024, 05:20 AM
              11 responses
              63 views
              0 likes
              Last Post halgo_boulder  
              Working...
              X