fxDreema

    • Register
    • Login
    • Search
    • Back to the main page
    • Categories
    • Recent
    • Tags
    • Popular
    • Search

    first condition start second second

    Questions & Answers
    2
    3
    1377
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • V
      varso last edited by

      Hii
      Please can you help me?
      i have this logic.
      In one indicator.
      when some condition happen it star find another condition and repeat this condition when this condition open buy ( or something else) we are go back to first condition and switch of second condition
      ( or the logic is that the condition look back on previos condition)
      I try to use turn On another block but i dont know if its corect.

      1 Reply Last reply Reply Quote 0
      • fxDreema
        fxDreema last edited by

        Look from NOW to the PAST. This chart you can see - this is all past data which is available for calculations. The same with indicators. Everything you can see on the chart is represented as numeric values in MetaTrader and they are available in every moment.

        EA works on every tick - when a new tick comes, you check something and do something if needed.

        1. Check condition(s)
        2. Do action(s)

        To get the value of the Nth candle from the past, there is a Candle ID parameter. If it is 10, this means that you work with the 10th candle from now to the past. That means you can check NOW what was happened in the PAST. There is no need to remember if some condition happens NOW and check that in the future, because this event (and many others) will be in the database.

        In short. When working with conditions in some EA, the way to deal with them is from now to the past - when a tick comes, you can have a condition that can check something that happened in the past only by setting Candle ID parameter (aka Shift parameter in MQL).

        1 Reply Last reply Reply Quote 0
        • V
          varso last edited by

          __Look from NOW to the PAST. This chart you can see - this is all past data which is available for calculations. The same with indicators. Everything you can see on the chart is represented as numeric values in MetaTrader and they are available in every moment.

          EA works on every tick - when a new tick comes, you check something and do something if needed.

          1. Check condition(s)
          2. Do action(s)

          To get the value of the Nth candle from the past, there is a Candle ID parameter. If it is 10, this means that you work with the 10th candle from now to the past. That means you can check NOW what was happened in the PAST. There is no need to remember if some condition happens NOW and check that in the future, because this event (and many others) will be in the database.

          In short. When working with conditions in some EA, the way to deal with them is from now to the past - when a tick comes, you can have a condition that can check something that happened in the past only by setting Candle ID parameter (aka Shift parameter in MQL).[/quote:21vwz6dd]
          oh my good
          Thank so much

          1 Reply Last reply Reply Quote 0
          • 1 / 1
          • First post
            Last post

          Online Users

          S
          A
          M
          R
          G
          T
          G
          Y
          C
          S
          S
          S
          A

          22
          Online

          146.7k
          Users

          22.4k
          Topics

          122.6k
          Posts

          Powered by NodeBB Forums | Contributors