MQL4 and MetaTrader 4 - page 60

  Grid Trade  (3)
Hi all expert, Would like to enquire a mq4 code question I have Opened a Buy trade. I'm trying to Open a 2nd Layer Grid trade after 50pips away from the first Trade entry price. No matter Profit or loss. And open Another 3rd Layer Grid trade after 50pips away from the first Trade entry price. No
Hello, I'm coding up an EA. In the EA, I get the following error while trying to modify an order: 0 12:35:41.007 Algorithm1 XAUUSD,H1: Failed. Order Modified 1.5To3 SLOrder #664704280, TPOrder #664695196, false 2025.94 2026.0. Error Code: 6 2 12:35:41.007 Algorithm1 XAUUSD,H1: ExpertRemove function
  Array Search  (4)
Hello! So I have this array of a struct: struct exmpl { double orderstoploss; int orderticket; string ordercomm; }; exmpl arr[]; And i have this function that i use for searching . Is not working on struct arrays. How can i search for a value in a array of a struct ? thanks
[Deleted]
  Print true  (3)
Say, I have this code bool A = true ; Print (A); The print output is 1 How to get it to print true, instead
Who helps me? I'm using * removed by moderator * mt4 for the binaries and to set the closing time I insert the number of minutes in the comment field but I don't know how to insert it in the expert advisor to get the closing and I don't know if it is right to insert the amount in euros instead of
Hello, please anyone help me write code in Mql4 for trailing pending orders. For instance when I open a buy position, I want my stop loss to be the same as my pending sell stop and trail them as market moves in an uptrend. Same for opposite Thanks
Hi Everyone I'm stuck. I'm trying to write a simple EA that would increase the lot size incrementally by 1 microlot every time that the equity drops incrementally by $200. So if my starting equity is $1000 and it drops to $800, the lot size of the next trade should go from 0.01 to 0.02. Then if the
Hello, I am writing my first Expert Advisor. When i use the compiler I get this message:End_of_program - unbalanced left parenthesis. How gen I resolve this? Thanks, Dropje
Hello guys please help me i want a expert advisor for MT4 which is delete all pending orders if there is no open order. if any open order no pending order is closed
hello, Is there a way for me to search for a specific message in my telegram channel, when SL or TP hited , reply to it using telegram's 'Reply' fonction? i try this but it didnt work. 20= index msg on telegram manually. Thanks, have a great day!. bool ReplyTelegramMessage( string url, string
  copy trader  (5)
hi guys, i want write a copy trade EA. but i dont know how i should send/receive info from an mt4 account to another account/accounts . i can a little python too,if it helps. should i use api
  Help with EA  (5)
I get unexpected end of program and unbalanced parentheses on the below code void OnTick ( void ) { double macdLine; double signalLine; double macdHist; 0 int start() { macdLine = iMACD ( "EURUSD" , PERIOD_M1 , 12 , 26 , 9 , PRICE_CLOSE , MODE_MAIN, 0 ); signalLine = iMACD ( "EURUSD"
I am searching something that would close all positions when a profit is targeted or a %, but without removing my robot that open positions. It can also be a % in the balance account to be targeted). Is it something possible on MT4? I search the net but I found only another Expert Advisor. So I have
[Deleted]
Hello, i have find a example at https://www.mql5.com/en/code/1998 wich allows to load a website with MetaTrader and this example is from MQL5 and should work also in the new MT4 build. But i am currently not enough experienced to make a simple working example, because the MQL5 language is still to...
I experience a very strange situation when I call TimeGMT(), it does not get executed on every tick although I have placed it in OnTick() event. For example, I placed the following code, it may have iterated hundreds of ticks times, and it will only sparingly print out the print statement containing
Hello! It is possible to integrate MetaTrader 4 with other payment system
hello there can anybody helps us code this strategy into a tradable ea it opens BUY/SELL trades based on the giving signals position as seems to be in the picture for TP and SL
  Make It No Repaint Please!  (890   1 2 3 4 5 ... 88 89)
I think time has come for this thread...Kindly place your repainters here...and...Voila!...they will become non - repainters, with my Magic touch and my programming skills... P.S.: You can place your decompiled, expired & ex files in here...makes no difference to me...the work will be done...that I...
I want to optimize my EA parameters to find the best set of parameters to trade. My computer is quite slow so it cannot be optimized on the Mt4 platform. Is there another way to optimize or is there a website to help optimize parameters? Introduce to me
This post is the continuation of a previous badly located https://www.mql5.com/en/forum/345284 Corrections have been made on the advice of coders. //+------------------------------------------------------------------+ //| eaxtwoependingaorders.5.volatility.mq4 | //|
//+------------------------------------------------------------------+ //| TicksSeparateVolume.mq4 | //| Copyright © 2008, FOREXflash. | //| http://www.metaquotes.net |
I'm asking for help with this error in my expert advisor's code: Failed to modify stop loss for short position (ticket #1). Error code : 4108. "OrderModify error 4108" I hope someone can help me, thanks. Here is the part of the code that returns the error: if (is_short_position && ticket > 0 &&
Hi all, new to MQ4 so reallyt stumped!!! I am trying to get the attached to only enter a trade at the start of a new bar when it meets the condition of being a bullish/bearish bar after 5 bearish or bullish candles. At the moment it does fire off a trade but it seems to so it when the condition is
hi to all guys I have a problem trying to install MT4 ( editor +terminal) with mt4setup.exe downloaded from https://www.metatrader4.com/en/download&nbsp ; the problem is that at the end of installation when the terminal open it is MT5 and not MT4.. Am i wrong ? there is something special during the
Hello everyone, I'm new to the EA world and I'm still learning how to backtest . At the end of every backtest I have a 100% drawdown and I've got no clue why, how can I solve this problem? It makes the report unreadable. Sorry for the (probably) stupid question
int start() /// Want to delete all pending orders  {   bool k;   double cls, Lot;   for(int i=0;i<=OrdersTotal();i++)      {      k=OrderSelect(i-1,SELECT_BY_POS);      int Ticket=OrderTicket();      Print(DoubleToStr(Ticket,3);                Lot=OrderLots();      if(OrderType()==0)...
Hi everyone. I'm a beginner at MQL4 . I've got a problem with getting the most value of an indicator for a specific time. Here's the exact thing I wanna do : I wanted an indicator which gives me the value for moving average of volumes. I have searched and found the indicator which I've attached
I am fairly new to trading and MT4, so I may be making a very silly mistake. The problem that I am having is that I code an EA and then I back test it. Then if I shut down my PC and come back the next day, and I back test the EA over the same period on the same symbol, I get completely different