fxDreema

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

    Problem with variables

    Questions & Answers
    2
    3
    529
    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.
    • E
      Eralcar last edited by

      Hi, I'm trying to create an EA that sells when the difference between 2 prices is greater or equal a certain value. I have created a double variable with value 0 and then I set a formula block that calculates the difference between the 2 relevant prices and stores the result in the initial variable. After this, the EA moves to a condition block that checks if the value in the variable is greater or equal a numeric value say 0.0010; in the condition block I've selected the function "Global variables" then I chose my varibale.
      Then the EA moves to a Sell Now block if the conditions are met. The problem is that when I download this EA and put in Metatrader nothing happens, even if a choose a small control number like 0.0001. Can anyone help me with this problem?

      Thank you very much for your attention

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

        http://prntscr.com/cqqe1w

        Put that "Variable" in Value -> Numeric instead

        Or better do everything in one Condition. Read the description of this block to see how to do it with the Adjust field

        1 Reply Last reply Reply Quote 0
        • E
          Eralcar last edited by

          thank you very much for your help 🙂

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

          Online Users

          L
          D
          B

          13
          Online

          146.9k
          Users

          22.4k
          Topics

          122.6k
          Posts

          Powered by NodeBB Forums | Contributors