fxDreema

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

    CONSTANTS...ARE TOO CONSTANT

    Questions & Answers
    3
    3
    540
    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.
    • 4
      4xFatigue last edited by

      So I created an EA where all my indicators can have a user define the Constant.

      (see RVIS ALL 1-1)

      However, I run the EA...no likey results, so I want to changed the settings.

      In the EA settings I change the values of these constants for each indicator and there is 0 change in the results.

      I even entered some extreme numbers that should render 0 trades for the EA just to see if the user input is doing anything at all and it is not.

      Am I not using this right?

      1 Reply Last reply Reply Quote 0
      • C
        Cgammons01 last edited by

        As far as using the Constants properly, all you have to do is create a Constant and be sure to link it to a field that holds a value. For example:

        You have placed a buy now and a sell now block on your workplace. Let's say you want to create a Lots Constant You create a constant: Type=double, Name= Lots, Value= 1.00

        Once that's done, double click on your buy block to open up the properties. In the box next to "Lot Size" right click on it and choose your "Lots" Constant. Do this same thing for your Sell block. You can do this with any of these types of blocks, indicators, conditions, etc. That's all you have to do and everything should work fine. I've made lot's of constants for my EA and all is working great.

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

          When you edit the settings of the EA once (in MetaTrader), they are cached and then if you change the inputs (Constants) in the EA, there is no change. There is some file created somewhere with the same name as the EA that holds your last used values. Maybe this is the problem

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

          Online Users

          H
          R
          A

          8
          Online

          146.7k
          Users

          22.4k
          Topics

          122.6k
          Posts

          Powered by NodeBB Forums | Contributors