fxDreema

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

    EA that closes all positions if +X/-X% is hit

    Questions & Answers
    3
    5
    1137
    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.
    • T
      Telfordstarb last edited by

      Anyone got an EA where it can close all running positions if X amount has been achieved or if X amount has been lost?

      Base values im after is 10% Profit = Close all trades and book the 10%
      And -5% = close all trades and take the -5% loss.

      I dont want it limited to a day, but more of a running EA that just waits till X amount has been hit then closed out.

      I short term invest and diversify all my positons across the market, This also helps with drawdown amounts due to a basket of different trades moving at once.
      However if my profit hits 10% id like to close all positions to book the 10% and the same if i lose 5%.

      I should note that this is for the base starting balance, Not running equity.

      jstap 1 Reply Last reply Reply Quote 0
      • jstap
        jstap @Telfordstarb last edited by

        @telfordstarb You need something like, when a trade is placed use balance/100*required % put into a variable, in a condition block when profit = variable close all trades.

        Learn fxDreema Without the Wait!

        My comprehensive book, available on Amazon, is packed with examples and invaluable insights to help you fast-track your learning journey.

        The paperback and hardback editions include MT4 & MT5 QR codes for easy access to all prebuilt projects and robots, including my latest gold trading robot!

        Don’t miss out

        Click here➡️ https://mybook.to/fxDreema to get your copy today!

        Enjoy! 😊

        1 Reply Last reply Reply Quote 0
        • T
          Telfordstarb last edited by

          How would i start that exactly? Im ok(ish) at the condition blocks but not the variables

          jstap 1 Reply Last reply Reply Quote 0
          • jstap
            jstap @Telfordstarb last edited by

            @telfordstarb Something like this, just add this to your project:

            https://fxdreema.com/shared/RJBTngscd

            Learn fxDreema Without the Wait!

            My comprehensive book, available on Amazon, is packed with examples and invaluable insights to help you fast-track your learning journey.

            The paperback and hardback editions include MT4 & MT5 QR codes for easy access to all prebuilt projects and robots, including my latest gold trading robot!

            Don’t miss out

            Click here➡️ https://mybook.to/fxDreema to get your copy today!

            Enjoy! 😊

            1 Reply Last reply Reply Quote 0
            • M
              mentor123 last edited by

              hi, i need so help, how to make ea that closes all trades once the previous loss is recovered by the current running profits. eg . if i just lost four dollars in the recent cosed trade, but i have a current trade now runing in four dollars or beyond, i want the ea to close that trade and i wait for other trading opportunites

              fvdscscasx

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

              Online Users

              S
              O
              K
              M
              M
              C

              26
              Online

              146.7k
              Users

              22.4k
              Topics

              122.6k
              Posts

              Powered by NodeBB Forums | Contributors