MQL4 and MetaTrader 4 - page 918

I think I've finished the beta version :-) Program to auto-optimise : https://www.mql5.com/ru/articles/1467 https://www.mql5.com/ru/code/7614 for automatic optimisation of Expert Advisor. Please test it and give your opinion, suggestions, critics, etc. I would be very grateful to those who speak
My EA has only up to one trade opened at any moment, but on certain bars it opens and closes mutliple trades, probably as many as the ticks in that bar. How can I prevent more than one or two trades opening in one bar?
[Deleted]
  Why does this return 0?  (16   1 2)
I am using the iSAR-Function in my EA. It is returning an accurate result. When, however, I try to add something, it returns 0: double SAR_C = iSAR(NULL,0,0.02,0.2,1)+0.00005; Print("SAR_C: "+SAR_C); This prints "SAR_C: 0.00000". Why is this? How can I prevent this/add something to the iSAR-Result?
i know c++ little and i know mql less than c++. how can i learn "building ea ?" is there any free guide or forum topic or link ?    pls help :) 
[Deleted]
Hello, Right now, I use the "History Center" in MT4 for historical data. GBPUSD H4 data only starts from the 2009.12. Do you know where can I get data prior to that date? Thank you, SC
Hello,  I just joined the Forum and I'm trying to find a way to turn OFF this information box that keeps popping up and blocks information underneath it. I'm using MT4.  Image attached and also at this link: http://amson.org/images/MT4-INFO-BOX-1.jpg Thank you, Chris.   
Hello! I am looking for a way to insert a watermark to display in all my charts? Right now, i am using the "Text" function for a watermark that carries Ariel Bold font with a 225 size. However, it's not practical, as it is sometimes mistakenly highlighted and deleted during charting activities. Any...
I am moving here from thinkorswim (trying to anyways). I wrote a "strategy" I used pretty successfully there which I would eventually try to get set up as an EA over here, but first I obviously need my indicators set up. Below is what I have for trendnoisebalance indicator thus far, and below the...
[Deleted]
Does it matter if I declare like this: int var;var++;  //Will it work,or do I need to assign zero to the var first like that?int var=0;var++;//Or it does not matter?Thank you.
New article The Random Sandbox has been published: The article includes an interactive "sandbox" as an Excel file which simulates randomized Expert Advisor backtest data. Readers can use this to help explore and more deeply understand the EA performance metrics offered by default with MetaTrader....
Hello. My English is bad. But I hope you understand my Problem.   I can not add the forexprediction.mq4 file (indicator) in any Chart in any Versions of different MT4 from any Brokers (MT4 from Admiral Markets, AVATrades, FXCM). The file is not crashed. Other user can it add to his Chart in MT4. I...
  Trade volume  (1)
If I need a $1000 margin to trade at $10 per pip, how much margin do I need to trade at $1 per pip?
Hello Forum, I am attempting to put together an indicator that draws a horizontal line of fixed length  to the right of current price action at the level of the most recent high and low fractals, and also draws trendlines through the 2 most recent high fractal positions 2 most recent low fractal...
  strategy refinement of the advisor  (71   1 2 3 4 5 ... 7 8)
Hello! Please help me to improve my Expert Advisor so that SL is set at LoW 4 bars And the trailing stop should be equal to a variable (any of them can be set), the variable should be a multiplier for SL For example SL is set as 30 pips so the trailing stop should be 30*(X) where x=any number I
Hello, I need some help finishing the attached code! As you can see from the code it is a martingale EA which doubles the lots traded per successive trade until a win is achieved. I am a very amateur coder so please excuse the errors.  Please see attached code for additional details to the strategy....
From what I understand, there should be a smille face next to the expert advisor when it is dragged to the chart. When I drag the expert advisor to the chart, the expert advisor shows up on the chart but instead of a smille face showing next to it, there is an x next to it. How do I activeate live
Hi everyone,   I have recently started trying to code with MT4 after using it for a few months and trying to get my head around the software. I have traded for a few years now and am really interested in creating my own EA's for backtesting/trading purposes, which i would also like to share on your...
Hello everybody, i'm searching an indicator that plot horizontal trend line every X pips from the current period open price. That's what i mean: on H1, M15, M5 and M1 the period is the DAY. So at the open of the day it draws a trend line ( from day begin to day end) at the current price, and at +20...
I have a great EA only to be let down by the strange behavoir of the kernell function: GetPrivateProfileStringA here is what is happening exactly documented here: https://www.mql5.com/en/forum/56876 in the code below: when the function is called for the second time: the line 1.Returned String=...
All my unpublished indicators are not working on the new metatrader 4 platform 500 build. Anyone knows whats going on?
[Deleted]
  Alembex  (2)
Quelqu'un pourrait m'aider a trouvé la logique pour programmer Alembex ? merci Voila la presentation : https://www.youtube.com/watch?v=2UrlFGrgA2c Someone could help me find the logic to program Alembex ? thank you Here is the presentation: https://www.youtube.com/watch?v=2UrlFGrgA2c  
Hi Guys, i tried to correct the error, I did not succeed. Iam wait for help... CODE: start error on the SyncProfit() //1 - OP_BUY //2 - MY MAGIC //3 - CURRECT SYMBOL //4 - TARGET PROFIT void SyncProfit( int ordertype, int magicnumber, string symbol, double lucro){ int total =
This is the old Universal Ma Cross Ea this version now can use any of the 17 different average, also this version is using a break even function if you want,and with a lock in pips, by default the lock in is set to 6 pips, to maybe help to stay under your brokers radar, and also by default the break...
[Deleted]
Hello, Probably a noob question but couldn't find and answer browsing the forum. I basicly have this setup : void CheckForOpen()resSL=OrderSend(Symbol(),OP_BUYSTOP, Lots, High[1]+1+Spread,1, High[1] - 5, High[1]+1+Spread + 5,"",MAGICMA,0, Blue); This part above is fine. Then when an order is there...
[Deleted]
Hi, By using iTime() I found an interesting situation I have opened the USDCHF M1 chart, and put into a script Print(iTime("USDCHF", PERIOD _M1,0)) it returned with 0. When I replaced "USDCHF" with Symbol() , Print(iTime(Symbol(), PERIOD _M1,0)); worked well. Can somebody help me ? Thank you F
I have two MT4 sessions open, each logged into a different account (on different brokers).  I wish to take a value from one terminal and pass it to the other (one way only).  The File Open, File Write, and File Close functions can only operate in the parent directory of the terminal that is doing...
what is the benefit of OrderCloseBy() ,compare to Order Close ?  
How can i run an expert advisor on my Android phone
I want to know how many cycle imbricated can be supported in mql4 ? I use more than 10 cycles imbricated in my EA and I want to make sure that no bug is diverted from it. I want to know it like Excel that support less than 7 cycles.
Good morning, Is there a way to force the indicator to reload from scratch? Like WindowRedraw but for the indicator. Thanks!