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

Place Hedge Order of unbalanced positions in MT4 – script MetaTrader 4

Place Hedge Order of unbalanced positions in MT4 - script for MetaTrader 4
This script calculates the total unbalanced postion of hedged or non hedged postions and then place hedge trades accordingly. Example  trader places 0.01 lot then 0.02 lot buy trade if then try to run the script , it will place 0.03 lot sell trade if again a sell trade is placed of lot size 0.05 … Read more

Alert at Order Closing – indicator MetaTrader 4

Alert at Order Closing - indicator for MetaTrader 4
Description: The indicator alerts at order closing, and reports about its profit. //+——————————————————————+ //|                                              AlertCloseOrder.mq4 | //|                               Copyright © 2010, Vladimir Hlystov | //|                                         | //+——————————————————————+ #property copyright “Copyright © 2010, Vladimir Hlystov” #property link      “” #property indicator_chart_window int Orders; //+——————————————————————+ int start()   {    if (Orders>OrdersTotal()) AlertOrder();    Orders=OrdersTotal();    return(0);   } //+——————————————————————+ void AlertOrder() { … Read more

Delete a Pending Order by Point and drop over the price order (green dashed line) – script MetaTrader 4

Delete a Pending Order by Point and drop over the price order (green dashed line) - script for MetaTrader 4
Description: Select the pending order you want to delete when you have severals pending orders on a same chart by point and drop over the price of the pending order you want to delete. You have severals pending orders placed on a chart and you want to delete one specific pending order? Just point a … Read more

Change your pending order PRICE, SL or TP by just drag and drop a script – script MetaTrader 4

Change your pending order PRICE, SL or TP by just drag and drop a script - script for MetaTrader 4
I have attached 3 scripts that will help you to modify the price, the Stop Loss and Take Profit of a pending order. Once you have added a pending order to your chart with a SL and a TP use the following scripts: DROP_MOVE_PENDING_PRICE.mq4 : If you want to move the price of your pending … Read more

Place OCO Order, One pip Limit Order and One Pip Stop Order – EA MetaTrader 4

Place OCO Order, One pip Limit Order and One Pip Stop Order - expert for MetaTrader 4
Description: Places One-Cancels-the-Other Order (OCO Order), One pip Limit Order and One Pip Stop Order on MetaTrader 4 (MT4) platform. Global variables: OCO_BUY_LIMIT – Buy Limit Price OCO_BUY_STOP – Buy Stop Price OCO_SELL_LIMIT – Sell Limit Price OCO_SELL_STOP – Sell Stop Price OCO_confirmation – After input Buy Limit Price, Buy Stop Price, Sell Limit Price … Read more