Beginner Programming: Moving Average Crossover with and without Martingale functionality – EA MetaTrader 5

Beginner Programming: Moving Average Crossover with and without Martingale functionality - expert for MetaTrader 5
All of the functions used in the Expert Advisor are found in the ImportantFunctions.mqh include file. There are 2 Expert Advisors, both using the price crossing the moving average as their entry signal, with a simple difference: one uses Martingale when losses occur, and the other does not. I don’t recommend using any of the … Read more

Calculate Lot Size and Trailling Stop – EA MetaTrader 5

Calculate Lot Size and Trailling Stop - expert for MetaTrader 5
I. Condition Buy-Sell 2. Backtest 1. Main function for calculate lot size //+——————————————————————+ //| caculate lot sisze Function                      | //+——————————————————————+ double calculate_lotsize(double sl, double price)   {   double lots=0.;   double lotstep= SymbolInfoDouble(_Symbol,SYMBOL_VOLUME_STEP); double ticksize = SymbolInfoDouble(_Symbol,SYMBOL_TRADE_TICK_SIZE);    double tickvalue = SymbolInfoDouble(_Symbol,SYMBOL_TRADE_TICK_VALUE);   double balance= AccountInfoDouble(ACCOUNT_BALANCE);   double point= SymbolInfoDouble(_Symbol,SYMBOL_POINT);   //double  loss=MathRound((MathAbs(price-sl)/ ticksize) * ticksize );   double  loss=MathAbs(price-sl)/point;  m_symbol.NormalizePrice(loss);   double Risk= initial_risk*balance;   if(loss!=0) … Read more

Trailing stop tutorial using ATR indicator – EA MetaTrader 5

Trailing stop tutorial using ATR indicator - expert for MetaTrader 5
I. Main function 1. Using condition buy or sell base on price action. 2. Auto caculate lot size 3. Auto trailling stop by ATR. 4. Backtest result II. Main function code 1. Trailling and count position function //+——————————————————————+ //|Count position and Trailling Functiom                              | //+——————————————————————+ void  count_position(int &count_buy, int &count_sell, double &_atr[])   {       count_buy=0; count_sell=0; … Read more

Lesson 9 Buy sell stop Order – EA MetaTrader 5

Lesson 9 Buy sell stop Order - expert for MetaTrader 5
I. Main function 1. Using condition buy or sell base on price action. 2. Auto caculate lot size 3. Auto trailling stop by ATR. 4. Backtest result II. Main tick function //+——————————————————————+ //| Expert tick function                                             | //+——————————————————————+ void OnTick() {    if(OpenBar(Symbol()))    {    OrderManaging(); // Candle declaration double High[],Low[],open[],close[]; ArraySetAsSeries(High,true);ArraySetAsSeries(Low,true);ArraySetAsSeries(close,true);ArraySetAsSeries(open,true); CopyHigh(Symbol(),timeframe,0,1000,High); CopyLow(Symbol(),timeframe,0,1000,Low); … Read more

Lesson 7 Price action Ket hop Volume VSA – EA MetaTrader 5

Lesson 7 Price action Ket hop Volume VSA - expert for MetaTrader 5
I. Main function 1. Auto caculate lot size 2. Auto trailling ATR 3. Using volume indicator and moving average indicator 4. Condition buy or sell 2. Backtest. II. Main function code 1. Volume indicator declaration //+——————————————————————+ //| Expert initialization function                                   | //+——————————————————————+ int OnInit()   { if(!m_symbol.Name(_Symbol)) return  INIT_FAILED; // Set Trade parameter trade.SetTypeFillingBySymbol(m_symbol.Name()); trade.SetExpertMagicNumber(m_magicnumber); trade.SetDeviationInPoints(Slippage); // … Read more

Lession 1_ Bullish and Bearllish Candle Tick – EA MetaTrader 5

Lession 1_ Bullish and Bearllish Candle Tick - expert for MetaTrader 5
I. Input parameter: II. Main function: 1.  How to create bullish and bearlish recognition conditions. 2. Only buy sell at new candle 3. Count position and trailling stop auto. 4. Lotsize is fix at input parameter setup. /////////////////////////////////////////////////////////////////////////////////////////////////////////////// Refer information: Link Exness IB Web: Các bạn đăng ký mở tài khoản Exness link IB dưới … Read more

Lesson 2_ Trading RSI Pattern Confirmation two Bottom – EA MetaTrader 5

Lesson 2_ Trading RSI Pattern Confirmation two Bottom - expert for MetaTrader 5
I. Input parameter: II. Main function: 1.  How to confirm condition entry. 2. Only buy sell at new candle 3. Count position and trailling stop auto. 4. Lotsize is fix at input parameter setup /////////////////////////////////////////////////////////////////////////////////////////////////////////////// Refer information: Link Exness IB Web: Các bạn đăng ký mở tài khoản Exness link IB dưới ủng hộ mình … Read more

Lesson 3_Price Action – EA MetaTrader 5

Lesson 3_Price Action - expert for MetaTrader 5
I. Input parameter: II. Main function: 1.  How to confirm condition entry. 2. Only buy sell at new candle 3. Count position and trailling stop auto. 4. Lotsize is fix at input parameter setup /////////////////////////////////////////////////////////////////////////////////////////////////////////////// Refer information: Link Exness IB Web: Các bạn đăng ký mở tài khoản Exness link IB dưới ủng hộ mình … Read more

Breakout Strategy with Prop Firm Helper Functions – EA MetaTrader 5

Breakout Strategy with Prop Firm Helper Functions - expert for MetaTrader 5
Hello all, This is an update of the “Simple Yet Effective Breakout Strategy”. In this code, I have added some helper functions for prop firm challenges. Generally, to pass a prop firm challenge, you need to satisfied three main criterias: Target profit Not violating maximum daily loss Not violating maximum loss In this code, I … Read more