fxDreema

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

    Help with multiple/basket orders for MT4

    General Discussions
    2
    18
    2176
    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.
    • D
      dalkungen last edited by

      Hi,

      Can anyone help me with a function to do a second basket order (if the signal hits again) after the currently open basket order moved stop loss to break even, if it is possible using fxDreema/MT4?

      So i want the open risk to be max one basket order. The basket order for me is 3 different orders with different take profits but same SL.

      Sequence example:

      1. Send three orders when signal hit first time.
      2. Take profit for first order is hit. Two orders from the first basket sill open.
      3. Trailing stop is moved to break even (or further using trail) on current basket order (2 open orders).
      4. Signal hits again with the two orders from the first basket order is still open.
      5. Second basket order of 3 orders are sent. This is the same orders as sent as basket 1 (exactly the same SL and TP) but it is only sent if the risk is zero on the first basket of orders, in this example the 2 open orders are at break even.

      So this last step is what i am struggling with.

      I have read the book by Andrew R. Young on Expert Advisor programming but i am not a programmer and don't understand the section on multiple orders and how i can modify it to fit my wish...

      Thanks very much for any help!

      l'andorrà 1 Reply Last reply Reply Quote 0
      • l'andorrà
        l'andorrà @dalkungen last edited by

        @dalkungen So if I understand it correctly, the EA is supposed to:

        1. Open three simultaneous trades every time market conditions are met. All of them have the same SL distance in pips but only the first one has a TP in pips.
        2. When TP of the first one is hit, the 2 remaining trades move their SL to BE.
        3. If market conditions are met again, 3 new trades are open with the exact same distance in pips for SL and TP as the first time.

        Is that correct?

        (English) I will try to help everyone in these fxDreema forums. But if you want to learn how to use the platform in depth or more quickly, I can help you with my introductory fxDreema course in English at https://www.theandorraninvestor.eu.

        (Català) Miraré d’ajudar tothom en aquests fòrums d’fxDreema. Tanmateix, si vols aprendre a fer servir la plataforma amb més profunditat o més de pressa, t’hi puc ajudar amb el meu curs d’introducció a fxDeema en català a https://www.theandorraninvestor.eu/ca.

        (Español) Intentaré ayudar a todo el mundo en estos foros de fxDreema. Sin embargo, si quieres aprender a usar la plataforma en profundidad o más deprisa, te puedo ayudar con mi curso de introducción a fxDreema en español en https://www.theandorraninvestor.eu/es.

        1 Reply Last reply Reply Quote 0
        • D
          dalkungen last edited by dalkungen

          @l-andorrà First, sorry for opening multiple treads. My first time using this forum. My mistake.

          No not exactly, i basically want to open the 3 new trades only if the SL has been moved atleast to BE on all previous trades. So looking for the condition that checks if previous bucket (3 trades) are risk free. The TP can have been hit or not in those first 3 trades. The important is that its risk fee but number of trades open can be many.

          I was watching your youtube clips as well. They are good!

          Thanks

          l'andorrà 1 Reply Last reply Reply Quote 0
          • l'andorrà
            l'andorrà @dalkungen last edited by

            @dalkungen So is point 1 correct? I think this is exactly what you are suggesting. If all trades have the same distance in pips what conditions are required for the SL to be moved to BE AFTER the first one hits TP?

            (English) I will try to help everyone in these fxDreema forums. But if you want to learn how to use the platform in depth or more quickly, I can help you with my introductory fxDreema course in English at https://www.theandorraninvestor.eu.

            (Català) Miraré d’ajudar tothom en aquests fòrums d’fxDreema. Tanmateix, si vols aprendre a fer servir la plataforma amb més profunditat o més de pressa, t’hi puc ajudar amb el meu curs d’introducció a fxDeema en català a https://www.theandorraninvestor.eu/ca.

            (Español) Intentaré ayudar a todo el mundo en estos foros de fxDreema. Sin embargo, si quieres aprender a usar la plataforma en profundidad o más deprisa, te puedo ayudar con mi curso de introducción a fxDreema en español en https://www.theandorraninvestor.eu/es.

            1 Reply Last reply Reply Quote 0
            • D
              dalkungen last edited by

              @l-andorrà The first point is correct in the way that it opens 3 trades simultaneously every time market conditions are met but only when risk of previous 3 trades has been moved to BE (zero risk). Basically, first time market conditions are met, i open 3 trades simultaneously with same SL in pips for all 3 (30 pips). All 3 trades has different TP, all in pips (preferable the trade with highest TP in pips will have a trailing stop in addition to the TP in pips). The SL is moved to BE for all 3 trades when price moved 25 pips in profit. At this point when SL is at BE, a second batch of 3 trades will open if market conditions are met. And so it continues, if SL for this second batch is moved to BE then another batch can open if conditions are met.

              So i open simultaneously 3 trades which together have my maximum exposure (30pips for each one of the 3 trades in the batch).

              Sorry if i explain poorly.

              l'andorrà 1 Reply Last reply Reply Quote 0
              • l'andorrà
                l'andorrà @dalkungen last edited by

                @dalkungen Ok. Now I understand it better. And is there any maximum number of open trades simultaeously or not? I tell you this because having many of them can be a problem depending on lot size.

                (English) I will try to help everyone in these fxDreema forums. But if you want to learn how to use the platform in depth or more quickly, I can help you with my introductory fxDreema course in English at https://www.theandorraninvestor.eu.

                (Català) Miraré d’ajudar tothom en aquests fòrums d’fxDreema. Tanmateix, si vols aprendre a fer servir la plataforma amb més profunditat o més de pressa, t’hi puc ajudar amb el meu curs d’introducció a fxDeema en català a https://www.theandorraninvestor.eu/ca.

                (Español) Intentaré ayudar a todo el mundo en estos foros de fxDreema. Sin embargo, si quieres aprender a usar la plataforma en profundidad o más deprisa, te puedo ayudar con mi curso de introducción a fxDreema en español en https://www.theandorraninvestor.eu/es.

                1 Reply Last reply Reply Quote 0
                • D
                  dalkungen last edited by

                  @l-andorrà ok great. I use 3 in a bucket but has not set a max for total number of trades open. But would be happy to stop adding trades after lets say 3 buckets so 9 trades total but could happily add more if possible as the risk should never be higher than for 3 trades anyway.

                  As long as the trend goes in my way i would be happy to add. However, if the trend continues TPs will start hit and the total number of trades will reduce from that as well. The first TP for the first of the trades in a bucket i use only 25bps so that comes off quite quickly for a trend move.

                  l'andorrà 1 Reply Last reply Reply Quote 0
                  • l'andorrà
                    l'andorrà @dalkungen last edited by

                    @dalkungen Ok. Do you have any initial project to begin with?

                    (English) I will try to help everyone in these fxDreema forums. But if you want to learn how to use the platform in depth or more quickly, I can help you with my introductory fxDreema course in English at https://www.theandorraninvestor.eu.

                    (Català) Miraré d’ajudar tothom en aquests fòrums d’fxDreema. Tanmateix, si vols aprendre a fer servir la plataforma amb més profunditat o més de pressa, t’hi puc ajudar amb el meu curs d’introducció a fxDeema en català a https://www.theandorraninvestor.eu/ca.

                    (Español) Intentaré ayudar a todo el mundo en estos foros de fxDreema. Sin embargo, si quieres aprender a usar la plataforma en profundidad o más deprisa, te puedo ayudar con mi curso de introducción a fxDreema en español en https://www.theandorraninvestor.eu/es.

                    1 Reply Last reply Reply Quote 0
                    • D
                      dalkungen last edited by dalkungen

                      @l-andorrà I am just using a simple condition with MA in this test to figure out how i can make the second "block" of trades to execute only after SL has been moved to BE. Currently i put in the 'Check trades count' to limit trades until it works.
                      As you can see i tried to just link the 'Break even point' to next set of trades.

                      0_1605733880990_be0cb85e-3ac4-42fd-b15f-686fcf5155f3-image.png

                      l'andorrà 1 Reply Last reply Reply Quote 0
                      • l'andorrà
                        l'andorrà @dalkungen last edited by

                        @dalkungen You need to disconnect blocks 12 and 13. In order to do that. You should create a boolean variable controling when break even happened and connect it below vblock 12. Then add a new condition block on top of block 13 pushing that the variable is active.

                        And don't forget to reinitiate the variable when necessary.

                        (English) I will try to help everyone in these fxDreema forums. But if you want to learn how to use the platform in depth or more quickly, I can help you with my introductory fxDreema course in English at https://www.theandorraninvestor.eu.

                        (Català) Miraré d’ajudar tothom en aquests fòrums d’fxDreema. Tanmateix, si vols aprendre a fer servir la plataforma amb més profunditat o més de pressa, t’hi puc ajudar amb el meu curs d’introducció a fxDeema en català a https://www.theandorraninvestor.eu/ca.

                        (Español) Intentaré ayudar a todo el mundo en estos foros de fxDreema. Sin embargo, si quieres aprender a usar la plataforma en profundidad o más deprisa, te puedo ayudar con mi curso de introducción a fxDreema en español en https://www.theandorraninvestor.eu/es.

                        1 Reply Last reply Reply Quote 0
                        • D
                          dalkungen last edited by dalkungen

                          @l-andorrà Hi again. Thanks for you comments. I tried to create the Condition after block 12 but with my limited knowledge of programming... what shall i write as the IF statement? i was trying to find in the name of SL moved to BE in the MetaEditor but no luck. The example in the picture is wrong but just so you can see if i am on the right way.

                          Do i need another block between 24 and 12? to push block 14 or will that be automatic if condition in block 24 is true?

                          Also, when you said i need to reinitiate, how do i do that?

                          ps, i deleted block 13 Check trades count as that is what i want to avoid having there but had it there before just to make it work at all.

                          I tried with a flag as well but couldnt get that to work.

                          Thanks again

                          0_1605963951996_d41b4d8b-6425-4f00-a8c1-5a969b611cf2-image.png

                          l'andorrà 1 Reply Last reply Reply Quote 0
                          • l'andorrà
                            l'andorrà @dalkungen last edited by

                            @dalkungen I didn't want to recommend the 'orange' condition block, but the 'yellow one'. Can you please share the link of your project instead of just a screenshot?

                            (English) I will try to help everyone in these fxDreema forums. But if you want to learn how to use the platform in depth or more quickly, I can help you with my introductory fxDreema course in English at https://www.theandorraninvestor.eu.

                            (Català) Miraré d’ajudar tothom en aquests fòrums d’fxDreema. Tanmateix, si vols aprendre a fer servir la plataforma amb més profunditat o més de pressa, t’hi puc ajudar amb el meu curs d’introducció a fxDeema en català a https://www.theandorraninvestor.eu/ca.

                            (Español) Intentaré ayudar a todo el mundo en estos foros de fxDreema. Sin embargo, si quieres aprender a usar la plataforma en profundidad o más deprisa, te puedo ayudar con mi curso de introducción a fxDreema en español en https://www.theandorraninvestor.eu/es.

                            1 Reply Last reply Reply Quote 0
                            • D
                              dalkungen last edited by dalkungen

                              @l-andorrà https://fxdreema.com/shared/75KIKIb1c

                              updated with variables: https://fxdreema.com/shared/qeEcwfUL
                              but now it doesnt work in the MT4 strategy tester...

                              l'andorrà 1 Reply Last reply Reply Quote 0
                              • l'andorrà
                                l'andorrà @dalkungen last edited by

                                @dalkungen I'm afraid I'm not a programmer so I have no idea what block 24 is doing in any case. Are you sure you need them?

                                (English) I will try to help everyone in these fxDreema forums. But if you want to learn how to use the platform in depth or more quickly, I can help you with my introductory fxDreema course in English at https://www.theandorraninvestor.eu.

                                (Català) Miraré d’ajudar tothom en aquests fòrums d’fxDreema. Tanmateix, si vols aprendre a fer servir la plataforma amb més profunditat o més de pressa, t’hi puc ajudar amb el meu curs d’introducció a fxDeema en català a https://www.theandorraninvestor.eu/ca.

                                (Español) Intentaré ayudar a todo el mundo en estos foros de fxDreema. Sin embargo, si quieres aprender a usar la plataforma en profundidad o más deprisa, te puedo ayudar con mi curso de introducción a fxDreema en español en https://www.theandorraninvestor.eu/es.

                                1 Reply Last reply Reply Quote 0
                                • D
                                  dalkungen last edited by dalkungen

                                  @l-andorrà
                                  No not in current state... i posted the link too early. Tried to update it here below. I wanted to create the calculation where StopLoss is moved to Open price/BreakEven and have that as a condition for next trade to open. So no new trade is opened before SL is moved to BE.
                                  Thanks for looking at it ealier though, i am learning from it. I will keep trying.

                                  https://fxdreema.com/shared/JK4CepNE

                                  l'andorrà 1 Reply Last reply Reply Quote 0
                                  • l'andorrà
                                    l'andorrà @dalkungen last edited by

                                    @dalkungen There is an easy alternative. Just create a boolean variable. Move it from false to true after the BE move. Then, in a different tree block, use a consition block on top of it requiring the variable to be true. Below it you can use then any other conditions required to open the new trades.

                                    (English) I will try to help everyone in these fxDreema forums. But if you want to learn how to use the platform in depth or more quickly, I can help you with my introductory fxDreema course in English at https://www.theandorraninvestor.eu.

                                    (Català) Miraré d’ajudar tothom en aquests fòrums d’fxDreema. Tanmateix, si vols aprendre a fer servir la plataforma amb més profunditat o més de pressa, t’hi puc ajudar amb el meu curs d’introducció a fxDeema en català a https://www.theandorraninvestor.eu/ca.

                                    (Español) Intentaré ayudar a todo el mundo en estos foros de fxDreema. Sin embargo, si quieres aprender a usar la plataforma en profundidad o más deprisa, te puedo ayudar con mi curso de introducción a fxDreema en español en https://www.theandorraninvestor.eu/es.

                                    1 Reply Last reply Reply Quote 0
                                    • D
                                      dalkungen last edited by dalkungen

                                      @l-andorrà ah ok now i understand. Sounds easy enough. I work with the Turn ON blocks after.
                                      Many thanks

                                      l'andorrà 1 Reply Last reply Reply Quote 0
                                      • l'andorrà
                                        l'andorrà @dalkungen last edited by

                                        @dalkungen You're welcome.

                                        (English) I will try to help everyone in these fxDreema forums. But if you want to learn how to use the platform in depth or more quickly, I can help you with my introductory fxDreema course in English at https://www.theandorraninvestor.eu.

                                        (Català) Miraré d’ajudar tothom en aquests fòrums d’fxDreema. Tanmateix, si vols aprendre a fer servir la plataforma amb més profunditat o més de pressa, t’hi puc ajudar amb el meu curs d’introducció a fxDeema en català a https://www.theandorraninvestor.eu/ca.

                                        (Español) Intentaré ayudar a todo el mundo en estos foros de fxDreema. Sin embargo, si quieres aprender a usar la plataforma en profundidad o más deprisa, te puedo ayudar con mi curso de introducción a fxDreema en español en https://www.theandorraninvestor.eu/es.

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

                                        Online Users

                                        W
                                        C

                                        9
                                        Online

                                        146.8k
                                        Users

                                        22.4k
                                        Topics

                                        122.6k
                                        Posts

                                        Powered by NodeBB Forums | Contributors