MQL4 and MetaTrader 4 - page 104

Counting open orders from an ae Guys I created this function that should count orders opened by an ea int OrdiniAperti( int MagicNumberint) { int count= 0 ; for ( int i = OrdersTotal ()- 1 ; i >= 0 ; i--) { int tcket = OrderSelect (i,SELECT_BY_POS,MODE_TRADES); if (OrderSymbol() == Symbol () &&
  validation ex4  (1)
Good evening, I have a problem validating an mt4 EA, <Deleted>, with the version for metatrader 5 I had no problems, can you help me? Thank you test on EURUSD,H1 there are no trading operations test on NZDUSD,H1 there are no trading operations test on GBPUSDcheck,M30 there are no trading operations
I wrote an article and submitted it for publishing on this MT4 site over six months ago. Since that time is has just sat there with the "ready for publishing" sign, but no messages or responses from admin. I think that it is the admin which is responsible for finally publishing it, and there is...
Hi all, thanks for getting in. A Gold EA is looking for two indicators, the one I can´t find is HLChannel.ex4. Any info would be very appreciated. Cheers
Hey, I wrote an indicator displaying me lines at highs and lows. Unfortunately, I get hundreds of lines as all bars of the chart are processed. I would prefer if the indicator just processes the last 500 bars or so. For the sake of convenience I've just inserted the part with the resistance. Can...
Hi Guys I have a custom indicator, which works fine when I attach it to a chart. When I attempt to get the values from the indicator, they are retrieved correctly as per the chart, when getting it from a script. If I use the same code that works in the script from an EA - I get values, but they are...
Hi! I am Latvian so I changed language to Latvian in MT4 and then I noticed, that one line is translated incorrectly. In Latvian MT4- OPTIONS-EXPERT ADVISORS there is incorrectly written "Atļaut padomniekiem veikt tirdzniecību" ("Allow EA make trades"), but it should be "Atslēgt padomniekus, kad
Hi, I'm trying to replicate a graphic Price Channel indicator and I've decided to right away copy and paste its code in my EA. The problem is that the indicator shows a value of 4 decimals when you hover the mouse on it, and I have no idea what's it doing: it's not rounding and it's not trimming
Hello, I have a question. If I have EA orders running and my computer reboot, after restarting my MT4, would the EA still be able to manage the running orders? Thanks
I am searching for someone to learn with, the wonderful language of MQL4 . I already understand and practiced a lot of the basis of MQL 4. &, like all, I have a few more things that I need to learn... I want to study, Share my knowledge, discuss things that one of us still didn’t understand and
Hi, every one when i apply the RSi and then drag the Momentum indicator to RSI subwindow the bottom subwindow will be happen but when i make an custom indicator like this code: //+------------------------------------------------------------------+ //|
Hi all, I have a strange error when my expert tries to close an order. I'm sure the condition is met, because I see the "Check" output in the Expert tab. The problem is that GetLastError() function return "0". if (Bid>= GlobalVariableGet ( StringConcatenate ( "Take_Profit_1_" ,OrderTicket() )) )
So I sent this "bug" to the service desk over 2 months ago, no response until it was closed out yesterday with no comment. I re-opened it today and asked if the bug was fixed. The response was "there is no bug" Here's the scenario (picture below). The backtested EA had an open sell at Friday...
[1] As you can see in the ERROR [3] gif, when I change the zoom level, the distance between the text labels and their corresponding levels change, which is not the desired outcome. The desired outcome would be for the text labels to remain a fixed distance away from their corresponding levels
I need help with my EA please, as you can see he has the parameters configured so that he only makes the purchase and sale, as well as closing them, I just need someone to help me and tell me how I can do so if this EA If you lose one trade, open the next one with twice the number of lots and with
Hello all i am experience some issue with an indicator that i am working on , can somebody please take a look and tell me why its causing this issue ? to put it simply the indicator is not refreshing Explanation: when i attach the indicator to the chart and leave it on, after sometime when i attach
Hi! I'd like to draw a fibonacci without click mt4 fibo button. It needs to my expert advisor. I'd like to use a simple button to start drawing. (Button code not good, but I think I can write to work good.) So, I need: click on the button, than click and HOLD on chart to start drawing fibo (fibo
The MT4 account is being entered, but it does not work. It has already been de-installed and reinstalled, but still does not work
Good afternoon friends, I am learning how some things work, and I have run into a problem that I do not understand. It is a multi-frame table for buying and selling (it is only a test to start a project). The problem is that if I use symbols , everything works fine, but if I use text, when I change
Dear Friends I am new to MQL4 language and trying to learn it, and building my own Expert for 2 Moving average crossover, I know there are some already built solutions, but I have some other logics to be incorporated so writing my own code, below is the basic version of my code where I dont see any
  MQL4  (4)
I am trying to download MQL4 NOT MQL5. Every time I go to download MQL4 on my laptop it automatically downloads MQL5. How do I fix this issue
void TouchedSR() { InsideResistance= false ; InsideSupport= false ; for ( int i= 0 ; i<10; i++) { double HiCandle = iHigh ( NULL , TradingTimeframe, i); double LoCandle = iLow ( NULL , TradingTimeframe, i); //Test for being inside a zone. if (LoCandle <= HI_Res &&
Hello. I'm using the mql4 standard library and using CListView created a list. Can somebody please tell me how can I change the listview background? To avoid misunderstandings, I mean, it's white by default and I want to change its color totally. I don't mean to change the border color or the
Can anyone add an Alert when apper Classical and Hidden Divergences in this indicator please? Thank you very much
int OnInit() { static double A = 0.1; //Buy static double B = 0.2; //Sell int Ticket1 = 0; int Ticket2 = 0; return(INIT_SUCCEEDED); } void OnTick() { Ticket1 = OrderSend(Symbol(),OP_BUY,A,up,1,cp-20*Point*10,cp+15*Point*10); Ticket2 =
Hi, i'd like to retrieve the latest closed pair specific (eurusd) closetime. However , i am seeing all related iterations. How could i choose (retrieve) the recent one? Responds are appreciated... void OnStart () { //--- for ( int i = 0 ; i <= OrdersHistoryTotal() - 1 ; i++ ) { if (
Hi Everyone. I have recently built a Moving Average cross over EA. My issue is that it sometimes places the same order twice and I cannot find the reason why. I only experience this issue when live trading (1M Charts) and the problem doesn't show up on Strategy Tester . Please note that I am a new
Hey y'all. Been programming recently, and was frustrated at how limiting and silly array searches are in MT4. So, I wrote some new ones. One for searching a single dim array, and one for searching a 2 dimensional array. I think they're kinda neat - maybe you will too. Also, in the file are 2 array...
Hello All, I am trying to set up push notifications to go to my iPhone MT4 app. the notifications come through on my desktop but at the end of the notification it says "not sent to *******" MetaQuotes number. Also, if I send a test alert it does not go through to my phone at all. How do I fix this