Expert Advisors • Indicators • Scripts • Libraries

MQL.RobotFX.org is the biggest collection of MetaTrader expert advisors (MT5 & MT4), indicators, scripts and libraries that can be used to improve trading results, minimize risks or simply automate trading tasks

MetaTrader 5 Expert Advisor | Exp TimesDirection

MetaTrader Experts, Indicators, Scripts and Libraries

The Expert Advisor opens and closes positions at the predefined moments in time.

EA inputs:

//+-------------------------------------------------+
//| Input parameters of the EA indicator            |
//+-------------------------------------------------+
input double MM=0.1; //Share of a deposit in a deal
input MarginMode MMMode=LOT; //lot value detection method
input int StopLoss_=1000; //stop loss in points
input int TakeProfit_=2000; //take profit in points
input int Deviation_=10; //max price deviation in points
input TradeMode Trade=ENUM_SELL; //Trade direction
input datetime OpenTime=D'1970.01.01 00:00'; //Position open time
input datetime CloseTime=D'3000.01.01 00:00'; //Position close time
input uint TradeInterval =60; //Trading interval in seconds (time accuracy for a trade)
//+-------------------------------------------------+
Note that the TradeAlgorithms.mqh library file allows using Expert Advisors with brokers who offer nonzero spread and the option of setting Stop Loss and Take Profit together with position opening. You can download more variants of the library at the following link: Trade Algorithms.
16811

Best MetaTrader Indicators + Profitable Expert Advisors