Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

StarDate and EndDate ?

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

    StarDate and EndDate ?

    Hi everybody

    How can I know the "Start Date" and the "End Date" of chart Data Series in my strategy code?

    Thanks!
    Last edited by ninjo; 03-02-2016, 06:57 AM.

    #2
    Somebody knows? Thank you !

    Comment


      #3
      Hello,

      Thank you for the question.

      If you are referring to the First and Last bars on the chart, you could use logic in OnBarUpdate to determine the specific bar times.

      Checking the First bar or bar 0's Time, and the Current Bars Time should achieve the Start and End times on the chart.

      Are you instead referring to the DataSeries menu and the EndDate and DaysToLoad?

      I look forward to being of further assistance.

      Comment


        #4
        I want to know the "Data Series" window Sart Date and End Date.



        Thank you !

        Comment


          #5
          I am testing...

          Time[0].ToString() return the date of the firstbar
          but
          Time[Bars.Count].ToString() return next error: "Bar index needs to be greater/equal 0"

          any idea?
          Thank you
          Last edited by ninjo; 03-03-2016, 02:20 AM.

          Comment


            #6
            Hello,

            The Current time would of course be Time[0] or zero bars ago, for the First time on the chart you could use:
            if(CurrentBar == 0) Print(Time[0]);

            That is just a print, you could store this as a variable for later use as well.

            Regarding the items in the DataSeries menu, there are not documented ways to get these specific values, instead using logic you could store the Time of bar 0 and the Time[0] on the CurrentBar to get the span of dates.

            I look forward to being of further assistance.

            Comment


              #7
              Is there a way to access those 2 controls using UIAutomationID in NT8?
              Would like to be able to programmatically access those Strategy Analyzer values during OnStateChange events.What are UI Automation IDs associated with them and any insights on how to use them would be appreciated.

              Thanks

              Comment


                #8
                Hello,

                Thank you for the reply.

                I am unsure if using an automation ID would be relevant in this case, the Automation ID points to a Control and the Property Grid is displaying an Objects data.

                You would need the actual Object to access its properties rather than the Property Grid.

                For any further assistance on this question, please post this question in the NT8 forum.

                I look forward to being of further assistance.

                Comment

                Latest Posts

                Collapse

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