fxDreema

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

    No trade/orders block doesn't work - EA keeps placing multiple orders

    Questions & Answers
    2
    11
    1085
    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.
    • K
      krunal20 last edited by

      Hello,

      I have built a pretty simple EA, consisting of 5 conditions based around EMAs and candle stick patterns followed by a pending buy order block but when I test the EA on MT4, it places thousands of orders at the same time when it passes all of the conditions. I have tried using the no trade and no pending orders block separately and have also tried to set an if trade/order block to be zero and only then looks for the conditions but still no luck.

      Appreciate any help on this.

      Thanks,
      Krunal

      1 Reply Last reply Reply Quote 0
      • K
        krunal20 last edited by

        0_1629438935491_Screenshot 2021-08-20 at 15.54.21.png

        1 Reply Last reply Reply Quote 0
        • max c
          max c last edited by

          https://fxdreema.com/shared/U3y2WDrNd

          place this before everything .
          also use candle ID 1 for condition blocks. as a good standard practice.

          1 Reply Last reply Reply Quote 0
          • K
            krunal20 last edited by

            Hi Max,

            Thanks for your reply. I had already set the candle ID to 1 as the strategy is all based on the previous candle. I'll try out the once per bar block to see if that helps.

            Thanks mate.

            1 Reply Last reply Reply Quote 0
            • K
              krunal20 last edited by

              Hey @max-c

              I've put the 'once per bar' block in at the top but it still seems to open multiple orders:

              0_1629440615695_Screenshot 2021-08-20 at 16.22.10.png

              max c 1 Reply Last reply Reply Quote 0
              • max c
                max c @krunal20 last edited by

                @krunal20 can you share link please. share project link left hand corner.

                K 1 Reply Last reply Reply Quote 0
                • K
                  krunal20 @max c last edited by krunal20

                  @max-c - Here you go mate:

                  max c 1 Reply Last reply Reply Quote 0
                  • max c
                    max c @krunal20 last edited by max c

                    @krunal20 have you tried connecting formula block to once per bar aswell.?
                    and block 5 candle open is greater than median price of itself? may not work

                    K 1 Reply Last reply Reply Quote 0
                    • K
                      krunal20 @max c last edited by

                      @max-c No, I haven't tried connecting the formula block to once per bar but i'm struggling to understand why I would need that. Happy to give it a try though.

                      So blocks 5, 6 & 7 are basically simulating a hammer candle (I wasn't sure how else to specify this), so block 5 is there to ensure the body of the candle is not larger than the range of the candle.

                      1 Reply Last reply Reply Quote 0
                      • K
                        krunal20 last edited by

                        @max-c - I've tried to connect the formula block to once per bar but still no luck. I've also tried to connect the buy order to once per bar too but still doesn't work.

                        Getting pretty frustrated because I thought the no trades/orders block should prevent the conditions from being activated if there's a live trade and/or order.

                        1 Reply Last reply Reply Quote 0
                        • K
                          krunal20 last edited by

                          Hi @max-c & for everyone's infomation. I've got it to work by directly linking the formula to the if no trade/order block and then all of the conditions after that. I think it was creating multiple orders because the EA wasn't checking if there were any live trades/orders before the formula and so it was passing straight through to the last condition before the buy order.

                          Thanks for the effort @max-c

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

                          Online Users

                          F
                          R
                          S
                          D
                          V
                          O

                          15
                          Online

                          146.7k
                          Users

                          22.4k
                          Topics

                          122.6k
                          Posts

                          Powered by NodeBB Forums | Contributors