Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

data values of drawobjects

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

    data values of drawobjects

    I saw on a previous thread this code to loop through the drawobjects... Is there any way to access the end points of a line once the desired line object is found?? The user interface shows data properties like Start Time and Start Y .... are these exposed? I don't see them as properties of the DrawObject.

    foreach(IDrawObject drawObject in DrawObjects)
    {
    if (drawObject.DrawType == DrawType.Ray && drawObject.Tag == "ABC")
    {
    // Do something here
    break;
    }
    }


    #2
    Yes, they are in fact exposed. We will post up an example early next week.
    RayNinjaTrader Customer Service

    Comment


      #3
      Thanks... looking forward to the example.

      Comment


        #4
        foxthorn,

        Please try the attached file. Before adding it to the chart draw several lines on your chart with color blue. Make some of the global objects and leave some of them as non-global. Bring up the Output Window and then add the indicator.

        The example shows how to change the color. You can just as easily get point values this way too.
        Attached Files
        Josh P.NinjaTrader Customer Service

        Comment


          #5
          Excellent! Thanks Josh.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by Geovanny Suaza, 02-11-2026, 06:32 PM
          0 responses
          626 views
          0 likes
          Last Post Geovanny Suaza  
          Started by Geovanny Suaza, 02-11-2026, 05:51 PM
          0 responses
          359 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
          562 views
          1 like
          Last Post Geovanny Suaza  
          Started by RFrosty, 01-28-2026, 06:49 PM
          0 responses
          567 views
          1 like
          Last Post RFrosty
          by RFrosty
           
          Working...
          X