Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

DrawRegionProblem

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

    DrawRegionProblem

    Hi all.

    I have solved the following problem with DrawRegion Method:

    The Indicators functionality is draw region inside the price chart ....

    1. draw three region (OK) /see screen1.jpg/
    2. draw six region (OK)
    3. draw three region and six region inside one price chart within one trading day (Problem)

    I want to use this indicator subsequently in this case:

    From 15:30 till 17:20 (CET) = draw three region
    From 17:20 till 22:00 (CET) = draw six region

    /see modified screen2.jpg/

    The problem come on at 17:20 when the indicator change three region to six.
    The six region doesn't start at 17:20, it starts at 15:30 and REPAINT the first part (15:30 - 17:20)!

    /see screen_problem.jpg/

    My question is: How to prohibit repainting of the first part (15:30 - 17:20)?

    Thank you in advanced!
    Attached Files

    #2
    maitreja, you probably access the wrong draw object tag ID and / or start/end bars ago if it does not repaint correctly on your set times - http://www.ninjatrader-support.com/H...rawRegion.html

    Comment


      #3
      Hi Bertrand. Thank you for answer, but I don't think so.
      There is condition when daily range of prices are > parameter, change display mode.
      I think it is better to join code
      maitreja
      Attached Files

      Comment


        #4
        Thanks - how would you plot 6 regions with this? I spot one input related to this and depending on the setting you either plot 3 regions or 2.

        Comment


          #5
          Yes, please use settings from the attached screenshot. If you will use today's NQ 09-09, you will see the same picture on your monitor.
          changes against basic ind. settings:
          1. C_middleColor to yellow - to see it on the white background
          2. P_divideParts - to true
          Attached Files

          Comment


            #6
            maitreja, thanks - the only DateTime comparison I see is the one where you check for the 15:30 time to start calcuations....unfortunately I don't see where you would make the 6 region swich at 17:20?

            Comment


              #7
              Yes, I have changed commentaries in code to english, sorry for czech :-)
              17:20 time is not exaactly time to change display type.
              Upper and lower thirds is dividing to next thirds or halfs, if the basic third is larger than predefined size (third value). In basic settings it means when difference between daily High and Low is larger then 15 points ( parameter P_thirdValue = 5).
              Attached Files

              Comment


                #8
                maitreja, thanks for the translated comments - I would suggest printing out the values you set for the region boundaries in the 'divide thirds in halfs' part...the lower ones appear to be 0.

                Comment

                Latest Posts

                Collapse

                Topics Statistics Last Post
                Started by Geovanny Suaza, 02-11-2026, 06:32 PM
                0 responses
                605 views
                0 likes
                Last Post Geovanny Suaza  
                Started by Geovanny Suaza, 02-11-2026, 05:51 PM
                0 responses
                351 views
                1 like
                Last Post Geovanny Suaza  
                Started by Mindset, 02-09-2026, 11:44 AM
                0 responses
                105 views
                0 likes
                Last Post Mindset
                by Mindset
                 
                Started by Geovanny Suaza, 02-02-2026, 12:30 PM
                0 responses
                560 views
                1 like
                Last Post Geovanny Suaza  
                Started by RFrosty, 01-28-2026, 06:49 PM
                0 responses
                561 views
                1 like
                Last Post RFrosty
                by RFrosty
                 
                Working...
                X