• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Changing signalName

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

    Changing signalName

    Hi,

    I cannot find an answer to this in the forum. In the documentation, most if not all of the managed order methods define signalName as "User defined signal name identifying the order generated. Max 50 characters". However, for SubmitOrderUnmanaged it states "A string representing the name of the order. Max 50 characters.".

    I use the unmanaged approach. In this case is 'signalName' still user-defined? I would like to change the signal name of the order once I get the order object back in OnOrderUpdate or OnExecutionUpdate. Can this be done, or does the NT engine use this value such that changing it might cause issues in the engine? Specifically, I am wanting to change the signalName before calling the ChangeOrder method, so I can track that I have changed the order.

    Thanks,

    #2
    Hello ChazJ,

    The signalName for order is actually supplied as a string and specified by the developer and is not specified by the user, unless the developer makes a separate string input and supplies this input as the parameter to the order. This is the same thing for managed or unmanaged orders.

    Yes, the signalName supplied for SubmitOrderUnmanaged will be the Name of the order in OnOrderUpdate/OnExecutionUpdate().

    Below is a link to examples that set the signalName in both managed and unmanaged approaches.
    https://ninjatrader.com/support/foru...269#post802269

    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Hi Chelsea,

      My question was whether I can change the signalName after the order has been created. Before submitting a call to the 'ChangeOrder' method, I want to change the signalName. Is that OK, or will that cause a problem in the NT engine? (See example below)

      private Order MyOrderObject;
      ...


      protected override void OnBarUpdate()
      {
      {
      ...
      if (entrysignal)
      {
      MyOrderObject = SubmitOrderUnmanaged(0, OrderAction.Buy, OrderType.Limit, 1, 1000, 0, "", "MySignalName");
      }
      ...
      if (MyOrderObject.State != OrderState.Filled)
      {
      MyOrderObject.Name = "NewSignalName"; // <== Will this cause a problem inside NT? Will the new signal name be maintained through the remainder of the object's life i.e., is there any chance NT may change it back to the original from an internally stored copy, perhaps?
      ChangeOrder(MyOrderObject, MyOrderObject.Quantity + 1, 1000, 0);
      }
      ...
      }
      ...
      }

      Thanks,

      Comment


        #4
        Hello ChazJ,

        No, the signalName for an order cannot be changed and this would cause internal issues.
        Chelsea B.NinjaTrader Customer Service

        Comment


          #5
          Dang! That is unfortunate!

          So I guess the only way for me to accomplish what I am looking for is to cancel the pending order and submit a new one. I was trying to avoid that as it just causes order churning at the exchange, plus the additional order management.

          Thanks for your help.

          Comment


            #6
            Hello ChazJ,

            Yes, the order would need to be cancelled and re-submitted.

            Why do you need the name of an order, which identifies that order, to change?
            Chelsea B.NinjaTrader Customer Service

            Comment


              #7
              When I open a position, I always place a disaster stop loss order with it. It has a signalName identifying it as a stop loss order. When I close out my position at any other time than a disaster stop, I just change the stop price of my stop loss order. When it executes the name is shown on the chart, and it appears as a disaster stop, rather than a profit taking or other position close. The name also appears in performance data and debug logs I write out. I would like to differentiate a closing order that is due to profit taking as opposed to a disaster stop loss.

              It would be nice if the 'ChangeOrder' method supported an additional parameter to change the signalName along with quantity, limit price and stop price.

              Comment


                #8
                Hello ChazJ,

                I will submit a feature request on your behalf for the development team to consider allowing signal names to be changed.

                Once I have a tracking ID for this request I will post in this thread for future reference.
                Chelsea B.NinjaTrader Customer Service

                Comment


                  #9
                  Thank you!

                  Comment


                    #10
                    Hello ChazJ,

                    I have received tracking ID# SFT-3441 for this request to change the signal name of an order.

                    As with all feature requests, interest is tracked before implementation is considered, so we cannot offer an ETA or promise of fulfillment. If implemented, it will be noted in the Release Notes page of the Help Guide.

                    Release Notes — https://ninjatrader.com/support/help...ease_notes.htm


                    Chelsea B.NinjaTrader Customer Service

                    Comment

                    Latest Posts

                    Collapse

                    Topics Statistics Last Post
                    Started by U0000999, Today, 05:44 AM
                    1 response
                    11 views
                    0 likes
                    Last Post NinjaTrader_ShawnB  
                    Started by Teebone21, Today, 10:38 AM
                    2 responses
                    9 views
                    0 likes
                    Last Post Teebone21  
                    Started by futurestrader7, Today, 11:31 AM
                    0 responses
                    3 views
                    0 likes
                    Last Post futurestrader7  
                    Started by J_o_s, 03-30-2020, 12:29 AM
                    2 responses
                    16 views
                    0 likes
                    Last Post J_o_s
                    by J_o_s
                     
                    Started by ptpatrader, Today, 10:27 AM
                    2 responses
                    8 views
                    0 likes
                    Last Post ptpatrader  
                    Working...
                    X