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 Max238, Today, 01:28 AM
          1 response
          22 views
          0 likes
          Last Post CactusMan  
          Started by giulyko00, Yesterday, 12:03 PM
          2 responses
          10 views
          0 likes
          Last Post giulyko00  
          Started by r68cervera, Today, 05:29 AM
          0 responses
          4 views
          0 likes
          Last Post r68cervera  
          Started by geddyisodin, Today, 05:20 AM
          0 responses
          6 views
          0 likes
          Last Post geddyisodin  
          Started by JonesJoker, 04-22-2024, 12:23 PM
          6 responses
          38 views
          0 likes
          Last Post JonesJoker  
          Working...
          X