Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Indicator not removed when removing Stategy

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

    Indicator not removed when removing Stategy

    I have a strategy that uses an indicator and this indicator plots on the chart just fine. If I remove the strategy, the indicator while not running is still displayed in the list of indicators after the strategy is removed from the chart.

    How can this happen and how to prevent it?

    Thanks,

    Leroy

    #2
    Hello Leroy,

    Thank you for your post.

    This is not possible, as the Strategy will add the indicators to the chart but there is no method to remove Indicators from the chart when only removing the Strategy.

    Please let me know if I may be of further assistance.
    Last edited by NinjaTrader_PatrickH; 07-11-2013, 06:32 AM.

    Comment


      #3
      Since the strategy does an Add(IndicatorBase ind)....why can't it do a Indicators.RemoveAt(0) for all indicators in OnTermination?

      or something like this:

      Code:
      while (this.Indicators.Count > 0)
      	Indicators.RemoveAt(0);
      Leroy

      Comment


        #4
        Hello Leroy,

        Thank you for your response.

        I will forward your suggestion to our development team.

        Comment


          #5
          Hello Leroy,

          Thank you for your patience.

          Do you have an example that I could use to re-create this on my end?

          When I apply a strategy to the chart that adds indicators it will remove those indicators when I remove the strategy from the chart.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by Mindset, 05-06-2023, 09:03 PM
          9 responses
          258 views
          0 likes
          Last Post ender_wiggum  
          Started by Mizzouman1, Today, 07:35 AM
          4 responses
          18 views
          0 likes
          Last Post Mizzouman1  
          Started by philmg, Today, 01:17 PM
          1 response
          6 views
          0 likes
          Last Post NinjaTrader_ChristopherJ  
          Started by cre8able, Today, 01:01 PM
          1 response
          8 views
          0 likes
          Last Post NinjaTrader_ChelseaB  
          Started by manitshah915, Today, 12:59 PM
          1 response
          5 views
          0 likes
          Last Post NinjaTrader_Erick  
          Working...
          X