Expert Advisors and Automated Trading - page 314

hey guys... during the Backtest, my EA suddenly breaks and stops opening trades(because there's no margin)  one specific parameter uses ATR and giving me the problem... the calculation for takeprofit and stoploss using the indicators are correct... what is making me crazy is that it goes through...
so obviously drawing lines is easy and setting new values to them is easy.. What im trying to do is make a line on the chart that mirrors the bid line and moves with it... As prices moves the line moves with it... But if i manually move the line to a certain level-- it will then stay there..  So its...
Hi All, Recently finished optimising an EA that performed really well on back testing.  Didn't report a single loss. On it's first day of running today however it has drastically failed and has been quite painful to watch. The spread was set correctly on back testing as there is a fixed spread on...
Hi, writing my first EA, which is also my first try in MQL language. Have been programming in other languages for a few years now. The question is : How I can calculate the time difference, since the last time my EA was used ? let's say , I don't want the EA to start , if it's less than 12 hours...
if i create a custom symbol similar to DXY, but which contains all of the symbols in the expert that i want to test then set the back-tester to test on that custom symbol (making sure the symbols actually tested are hard coded into the algo), will i end up with a compiled time-series of ticks for...
Dear all, When I try to run EA on many symbols by attaching it to one chart in live trading, it shows the error about reading indicators like this but it can work in Strategy Tester mode. My code is mainly in OnTick() Please give me a suggestion what is the cause of this problem and how to fixed it....
Hello everyone! I've two questions: 1) Removing comments from source code would increase the performance of the EA in terms of back-testing speeds? 2) Could some one share a good course (free or paid) to learn MQL5 programming? Thanks! Best Regards, Fernando.
I am just starting to build my first EA. I have written an easy indicator, which is working perfect when attaching to a chart in Meta Trader 5. Also when I debug the indicator all is very fine. As a result from my indicator I can see the arrows plotted to the chart. But when I try to start the...
...like a MQL5 indicator could? Or like WHS Nanotrader can? Not just the default (straight) line, but a curve, e.g. that of a parabolic SL. If yes: how? If no: what‘s next best solution? And will they also show in the strategy tester (backtesting) visualization? Thank you very much!
Hello you all,  I have a problem and i dont know how to solve it.  I want to make an expert that opens trades bij some kinde of signal that comes out a text, or a CSV file. If somebody hase some kind of expert that uses this kind of Technic or has experiance with it please help me out!.  
Hi, I would like some help do code the following EA. I have noticed that EJ often bounce or get rejected at the 100 round numbers (136,135 etc) So what I would like is an EA that place a Sell limit at the upper round number and a Buy limit at the low. The orders should be created when price touch...
[Deleted]
I'm new to programming mql4. can you change trade comment when ordersend is rejected (ERR_NOT_ENOUGH_MONEY)? I send this order int OrderSent(symbol,OP_BUYSTOP,1,price,3,stoploss,takeprofit,"recoverBuy",magic,0,clrBlue); if so, how do I change trade comment?
Dear MQL5 community, First of all I'd like to say I'm not the kind of guy to randomly post a question every time I stumble upon an issue. As a matter of fact this is my first post here ever even though I've been using MQL5 for years and coded multiple EAs of varying complexity, some of which running...
Hi! I need to convert a .mql5 file into .mqh so that I can use it in the EA. Is it necessarily to convert the files? Can I just copy and paste it into a robot? Can you also direct me to the documentation to learn the conversion. Your help will be much appreciated. THANKS.
Hello, I would like to know if its possible to edit .mq4 file by script. The point is to permanently change default settings of EA because its to much time consuming work to do that for each EAs when I do massive loading on demo account. I would like to somehow load source code of mq4 file by script...
  EA demo  (2)
how to set datetime limitation on tester and real?
I'm currently coding my first binary ea which is based on price simply crossing above the upper and lower line of the Bollinger Bands. The problem I'm having is I want the order to executed as soon as the candle starts. So for example for a sell trade the previous candle cross the upper line and as...
Hello, does anyone have an idea  i want to selct positions and therefore i also check the Position_open_time with followng code datetime position_time = PositionGetInteger(POSITION_TIME); when i compile i get following message possible loss of data due to type conversion and i dont understand why....
  Global Variables  (1)
Hello, does anyone know, how to use global variables on MT5 strategy tester? amando
Hi, I have an EA which places limit/stop orders. The issue I am facing is that I see the filled orders showing up on the chart but not the placed limit/stop orders. On Metatrader 4 however I can see both. Is there any setting I should be looking at? Google did not help unfortunately. Zz
Hi Everyone! I am new to mql5,and I decided to write my own EA.Thing is that I'd like to add some custom tools to help me with trades,and I want them to be on some kind of multitab form. But I have no idea how to create forms,controls or where to even start.I shouldn't have problems with other
  Chartless EA  (2)
I want to build an EA that can look at the entire market and make trades without me having to open a trade window. Is this possible? I also have multiple demo accounts so I can test different aspects of the EA I want to build. For example. I want my EA to rely on data from a stochastics Indicator...
Im trying to get a comment of my last MFE and i cant figure out how to do it. Ive done this. Probably all wrong but, please help. double OpenPrice;    double High[];    ArraySetAsSeries(High,true);    CopyHigh(_Symbol,PERIOD_M1,TICK_FLAG_ASK,PRICE_OPEN,High);    OpenPrice= ArrayMaximum(High...
Hi  I'm getting the "Invalid Expiration" message - not on my machine but on a users machine.... I did a search but couldn't find anything for this specific case. We first saw the issue last week when he was submitting Time In Force to GTC on limit & stop orders. He's in Brazil and it rejected every...
  Ea arbitrage  (1)
Do someone know best arbitrage between broker
Good afternoon: I need to know if MT5 provides me these two values (Ask Volume and Bid Volume) Someone could tell me if I can get these values? If it is correct, which is explained in the manual MT5. Thank you very much. Hermo.
HFT project using supercomputer, 3 digit stable year return Tech task created, developer found, let's discuss strategy and get started
when you focus an OBJ_EDIT. Please have a look on this code: void OnChartEvent(const int id,                  const long &lparam,                  const double &dparam,                  const string &sparam)  {//---        switch(id)      {         case CHARTEVENT_KEYDOWN:...
Hello! I have a demo account and in my client Trade tab I can see that I have 10000 Balance, Equity, and Free margin but when I call AccountInfoDouble(ACCOUNT_BALANCE) in my Expert Advisor I get returned 0, this also happens with Equity and Free Margin. Might this be because this is a demo account...
hi guys ... i need help on my EA .... whenever i load my custom made EA into juz 4 charts.. it shows this error .. "CApp Dialog: Find Subwindow Error".... and this message keeps repeatedly shown on the experts logs continuously.... can  anyone clear this for me as to y this is being shown...?