Announcement

Collapse
No announcement yet.

Elapsed Bar Time

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

  • Elapsed Bar Time

    Alex posted the attached file elapsedbartime.efs, however this does not work. Does anyone have a corrected version that works?

    Thanks
    Attached Files

  • #2
    Worked here for me, what error did you get?

    Did you notice the counter is to the right of the price bars, might be off your screen?

    Comment


    • #3
      The display location on the chart is fine. It does not reset to '0' at the beginning of a new bar. It only resets to '0' when the eSignal application clock on the lower left hand corner starts a new minute. The display then counts to the mid-twenties (in seconds), and then stops and does nothing until the eSignal clock reaches the start of a new minute again, regardless of the bars.

      Comment


      • #4
        Vailskier
        As you can see in the enclosed images the script you posted is working as expected at my end [with at the most a discrepancy of 1 second now and then between the program's clock and the time displayed by the efs]. Also the timer is resetting at the beginning of each new bar
        Alex








        Originally posted by Vailskier
        The display location on the chart is fine. It does not reset to '0' at the beginning of a new bar. It only resets to '0' when the eSignal application clock on the lower left hand corner starts a new minute. The display then counts to the mid-twenties (in seconds), and then stops and does nothing until the eSignal clock reaches the start of a new minute again, regardless of the bars.

        Comment


        • #5
          Hi Alex

          From the efs:

          if (getCurrentBarIndex() < -1) return;

          what does it mean (What does it do? Why do you need it?) I am having a problem understand why you would need it? Thanks.

          Comment


          • #6
            Ted608
            See this article in the EFS KnowledgeBase regarding the getCurrentBarIndex() function and see section 2.4.4 in the Beginner Tutorial 2: Commonly Used Core JavaScript (also in the EFS KnowledgeBase) regarding the return statement and its use
            Alex

            Originally posted by Ted608 View Post
            Hi Alex

            From the efs:

            if (getCurrentBarIndex() < -1) return;

            what does it mean (What does it do? Why do you need it?) I am having a problem understand why you would need it? Thanks.

            Comment


            • #7
              Hi Alex

              Thank you very much for your quick response!

              I will read & try to understand it this time.

              Wish you have a wonderful & safe holiday.

              Ted

              Comment


              • #8
                Ted
                You are welcome and FYI that line of code simply interrupts execution of the script if the index of the bar being processed is less than -1
                Alex


                Originally posted by Ted608 View Post
                Hi Alex

                Thank you very much for your quick response!

                I will read & try to understand it this time.

                Wish you have a wonderful & safe holiday.

                Ted

                Comment

                Working...
                X