fxDreema

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

    bucle :(

    Questions & Answers
    3
    7
    1885
    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.
    • PurpleCash
      PurpleCash last edited by

      I need everything to be repeated if the conditions are not passed. but I do not want to connect block 3 with all the conditions (5,6,7,8,9,10). thank you0_1540943508582_foro1.png

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

        +1 need solution plz

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

          I don't understand what is going on here. What do you mean when you say that everything needs to be repeated, what is "everything"?

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

            https://fxdreema.com/shared/8OxH0V3bb

            error: EURUSD,H1: zero divide in '17463-45345.mq4' (3490,80)

            This basic program does not work. I want the ea to look for the high candle with two minimums at the sides (fractal), the ea should start searching between the periods 40-30 and go down to 10-0. I'm using the translator and I'm sorry.
            Do you have examples of how to create loops that add value to a constant?
            regards

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

              +1 plzz helpp

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

                You are using variable pivothigh as a SL level, but this variable is never modified and its initial value is 0. As a result SL is 0. And then "Risk fixed amount of money" requires that SL is different that 0. The error comes from one function that calculates the lot size using SL.

                1 Reply Last reply Reply Quote 0
                • Andermaiden2nd
                  Andermaiden2nd @PurpleCash last edited by

                  @purplecash Creo que entiendo lo que quieres hacer, pero no te va a funcionar con esos bloques por varias razones.

                  1. Para empezar te vendería en cada tick (luego de hacer cuatro veces unos cuantos chequeos que no afectan nada porque no están conectados a nada) si no fuera porque antes te va a dar un error lo que nos lleva al siguiente punto.
                  2. Lo que viene luego del bloque de bucle hace lo siguiente: primero asigna a una variable "periodhigh" el valor -10 (las variables son cero por defecto) y luego intenta asignarle a una variable "vela high" el precio más alto de un período de velas que está en negativo por lo que va a dar un error por que esas velas todavía no ocurrieron (la ID de las velas aumenta en números positivos cuanto más atras uno vaya siendo la de ID "cero" la vela actual, la "uno" la anterior, la "dos" la de dos velas para atrás, etc.)

                  Esto debería funcionar aunque no lo he probado.
                  https://fxdreema.com/shared/z6zQXvFud

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

                  Online Users

                  B
                  T
                  P
                  C
                  S
                  T
                  I
                  B
                  A

                  26
                  Online

                  146.7k
                  Users

                  22.4k
                  Topics

                  122.6k
                  Posts

                  Powered by NodeBB Forums | Contributors