Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Limit the number or rays drawn

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

    Limit the number or rays drawn

    So I know how to make multiple rays on charts and I know how to make a single ray.

    Code:
    DrawRay("MyRay"+CurrentBar, 8, MAX(High,9)[0], 0, MAX(High,9)[0], Color.Green);
    It is possible to limit the number of rays drawn on a chart? For example, say I want to draw the last three, not every one.

    #2
    You could try the following (not tested) code:

    Code:
    DrawRay("MyRay" + (CurrentBar [B][COLOR=blue]% 3[/COLOR][/B]), 8, MAX(High,9)[0], 0, MAX(High,9)[0], Color.Green);
    Regards
    Ralph

    Comment


      #3
      Thanks for sharing your idea Ralph!

      Comment


        #4
        That worked. Thanks.

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Geovanny Suaza, 02-11-2026, 06:32 PM
        0 responses
        574 views
        0 likes
        Last Post Geovanny Suaza  
        Started by Geovanny Suaza, 02-11-2026, 05:51 PM
        0 responses
        332 views
        1 like
        Last Post Geovanny Suaza  
        Started by Mindset, 02-09-2026, 11:44 AM
        0 responses
        101 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Started by Geovanny Suaza, 02-02-2026, 12:30 PM
        0 responses
        553 views
        1 like
        Last Post Geovanny Suaza  
        Started by RFrosty, 01-28-2026, 06:49 PM
        0 responses
        551 views
        1 like
        Last Post RFrosty
        by RFrosty
         
        Working...
        X