fxDreema

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

    Set take profit based on stop loss?

    Questions & Answers
    2
    4
    759
    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.
    • S
      smeden last edited by

      Hi
      I set my stoploss based on an indicator. So after the stop is set I want to set the take profit based on the stop loss.

      so if the stop is 20 pips I want the take profit to be 40. Is there a easy way to do this?

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

        2 ways in this example: https://fxdreema.com/shared/43WHI9Ulb

        The Buy trade is opened with SL and TP of 20 pips, and then TP is modified as 200% of SL. Note that in "For each Trade" there is value 1 in the last parameter, which means that the very last trade (the one that was just created) is loaded in it and then modified.
        And the Sell trade is opened directly with SL = 20 and TP = 2 x SL. For this I used a Variable named "MyStopLoss" which holds the value of 20.

        1 Reply Last reply Reply Quote 0
        • S
          smeden last edited by

          Thanks thats awsome.

          another quick question. If I only got the ex4 file of an indicator and want to use it as a condition. Is there a way I can set the name and choose buffers on my own? So I dont have to change the code manualy? Much easier to have it all in the software...

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

            In the past all input parameters were accessible in .ex4 files, but now nothing can be read from there, or at least I don't know how. Well, copyright information can be read, but who cares.

            I wrote some information in the window where indicators are organized, also look at the bottom half of this page to see what datatypes to use for parameters: https://fxdreema.com/documentation/proj ... indicators

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

            Online Users

            15
            Online

            146.8k
            Users

            22.4k
            Topics

            122.6k
            Posts

            Powered by NodeBB Forums | Contributors