fxDreema

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

    Changing Variable/Constants Names Breaks Stuff?

    Questions & Answers
    2
    3
    481
    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.
    • MrDaisyBates
      MrDaisyBates last edited by

      I had an EA that was working great, but I wanted to make a V2.

      I imported the MQL file into the builder and named it with V2.

      I decided to rename a variable (from Total Trade Risk to BaseRisk). It was used in calculations for % Risked per trade.

      Once I change that, I added a bunch of stuff to the EA, but I didn't mess with the original stuff. (What I mean is, I have a criteria when my balance is at or below starting balance, keep doing the exact same thing as before. I added a new branch off of a condition that balance had increased, basically and that's where the new stuff happened). So, I left all the original stuff untouched.

      It went from placing lots from 0.05-0.11 or so based on the SL and stuff.

      Now? Every single trade is 0.01 lots. I've been trouble shooting for like an hour and all I can remember doing that might have affected it is renaming that constant.

      Does this often break stuff? It appears the builder renamed it in all the boxes that I used it in, but for some reason...this issue is a thing.

      roar 1 Reply Last reply Reply Quote 0
      • roar
        roar @MrDaisyBates last edited by

        @cdwilder1 yeah, sometimes the names break. I dont know about "BaseRisk", but there are certain reserved variable names in the general structure of fxdreema code - if you accidentally pick some of those reserved names, you going to have bad time

        Need small help? Tag me in your post
        Need big help? https://www.fiverr.com/big_algo/automate-your-winning-strategy-in-mql4-or-mql5

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

          Oh, goodness, @roar hahaha

          I added a bunch of new variables and stuff to the project, also, just not in that area. So, reverse variables? It does the opposite of what's stored in the variable or something?

          I guess there's no list of these or something anywhere? My project has like 20 variables and another 20+ constants hahaha.

          Thanks for the reply.

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

          Online Users

          C
          M
          M
          F
          L
          F
          F
          E
          K
          M
          T
          A

          33
          Online

          146.6k
          Users

          22.4k
          Topics

          122.6k
          Posts

          Powered by NodeBB Forums | Contributors