• 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

Exit position without knowing entry signal name

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

    Exit position without knowing entry signal name

    Hello,

    The only overloaded method for ExitLong that allows for the barsInProgressIndex parameter is the following:

    ExitLong
    (int barsInProgressIndex, int quantity, string signalName, string fromEntrySignal)

    This method requires the fromEntrySignal parameter. When exiting positions opened in previous days of real-time trading, the system does not know the value of fromEntrySignal. How do I get around it? If not, can you please create the following overloaded method:

    ExitLong(int barsInProgressIndex, int quantity, string signalName)

    Thank you!

    #2
    Hello,

    If you do not wish to assign a fromentrysignal you can give it the empty string "" and this will have the same effect as your suggested overload.

    That said do you have a sample strategy that replicates the error your seeing so that I may test on my end?
    Lance B.NinjaTrader Customer Service

    Comment


      #3
      Lance,

      I tried what you suggested, and it worked! Thanks a lot for your help!

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by 911C4S, Today, 06:51 AM
      0 responses
      5 views
      0 likes
      Last Post 911C4S
      by 911C4S
       
      Started by dlanthana, Today, 06:24 AM
      0 responses
      11 views
      0 likes
      Last Post dlanthana  
      Started by cupir2, 10-13-2018, 04:39 PM
      8 responses
      70 views
      0 likes
      Last Post NinjaTrader_JaredM  
      Started by jg123, Today, 03:34 AM
      0 responses
      8 views
      0 likes
      Last Post jg123
      by jg123
       
      Started by Zeos6, Today, 02:48 AM
      0 responses
      5 views
      0 likes
      Last Post Zeos6
      by Zeos6
       
      Working...
      X