fxDreema

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

    Selection dropdown?

    Questions & Answers
    2
    5
    1218
    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.
    • C
      coverman last edited by

      Is there a way to make a selection menu where I can pick different settings within an EA?
      Where do I make this part in FxDreema and is there a way to show a name for the selction, but use a setting hidden for the user? Something like EASY, MEDIUM and HARD and if they pick one of these, the code will use 10, 50 or 90 for the setting (not shown for the user).

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

        If you want to put such thing on the chart, I'm not sure that MT4/MT5 can do that, at least I can't find something like this in their list of objects: http://docs.mql4.com/constants/objectco ... num_object

        If you define "Constants", they will be also input parameters of the EA. In the builder, let's say under "on Init", depending on the value of the Constants you can modify some Variables. Variables and Constants are both global variables, but Variables are hidden from the outside world.

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

          Well, it's the constants that I want to be selected. I wonder if it's possible to put three different numbers there, where the user can select.
          I think I've seen that before in an EA. When I go to the properties window in MT4 I get a dropdown to select an option. I guess that is something I should add in the constants here? But how?

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

            Like the image added where I can select true or false.

            ......
            Skärmavbild 2015-10-06 kl. 16.25.23.png

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

              For these to show up, the data type of the Constant must be... let's say special. There is a big list of what they call "Enumerations", here is just onbe of them as example: https://www.mql5.com/en/docs/constants/ ... t_position So, the data type here is this one ENUM_CHART_POSITION and if you use this as a data type for a Constant, it should create a dropdown list with 3 options in it.

              Also, custom Enumerations can be created, but even I am not using this functionality in the code of fxDreema. Here is more: https://www.mql5.com/en/docs/basis/type ... numeration

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

              Online Users

              D
              A
              M
              K
              M
              B

              15
              Online

              146.7k
              Users

              22.4k
              Topics

              122.6k
              Posts

              Powered by NodeBB Forums | Contributors