0

I need to write "Decrease & Increase" function code for "LOT_MINUS_LABEL".

int OnInit() {
    ObjectCreate ( 0, "LOT_MINUS_LABEL", OBJ_LABEL, 0, 0, 0 );
}
int OnChartEvent()
{
 MarketInfo(Symbol, MODE_LOTSTEP);
}
user3666197
  • 1
  • 6
  • 50
  • 92
Max-Enrik
  • 61
  • 13

1 Answers1

0

The GUI-Objects v/s MMI-Add-On-s in the MT4 Context:

While MQL4 has evolved in several waves into a still creeping New-MQL4.56789, there are some MetaTrader Terminal context, that has restrictions to keep in mind.

After many years in pure-charting GUI, MetaQuotes Inc. has come with a few "innovative" toys, that were somehow visually pleasing the audience --- "One-Click-Trading"-GUI-complete-MVC-Panel being such example, or the "Depth-Of-Market"-GUI-Visualiser-Only-Panel.

The point is, that both of these "add-on"-s had zero-API available and any of your needs thus remained just for as-is viewing these isolated MMI-gadgets, whereas the real Scripted / EA-driven usage of neither a "OneClickTrading" nor the "Depth-of-Market" values ( the less the BuySell actors available in "OCT" ) were simply out of one's reach.

The Code:

The snippet is far from showing any direction or any requirement specification or at least some inventory of key core/non-core functionalities intended to be operated in the final state.

Let me thus comment on the obvious items the code has to resolve before making it at least a compile-ready one:

int OnInit() {
    ObjectCreate ( 0, "LOT_MINUS_LABEL", OBJ_LABEL, 0, 0, 0 );
}

int OnChartEvent() {                          // function declared to return int
    MarketInfo( _Symbol, MODE_LOTSTEP );      // function call returns a value
                                              //          but does not assign it
                                              //          to anything, so is lost
}                                             // }-EndOfFunc & MUST RETURN(INT)
user3666197
  • 1
  • 6
  • 50
  • 92
  • I spent a lot time but I do not get any good result for "LOT" decrease and increase, so can you help me? Best. (Also I still working for it) – Max-Enrik Oct 08 '16 at 22:26