Hey everyone, I'm trying to figure out the best way to store a value in a buffer similar to CopyBuffer, but the value isn't from an indicator. Id like the EA to check if the value is higher or lower than the previous bar. Something like this: if(MyValue[ 0 ] < MyValue[ 1 ]) { //Do something...; }
I want the MQL5 code that making my EA dose not open deals at a specific times ex: do not open deals from 03:00 to 04:30 and from 11:00 to13:30
The strategy tester loads my EAs in memory and does not delete them even if I make modifications to them ... Even if i overwrite the binary file... This is very annoying !! Is there a way to prevent this from happening? Maybe something in the settings? Thank you
I have a pretty good EA (mq5 ).Now I need the Time filter .Where can I find the code for the Time filter (mq5) or a sample EA with the Time filter code in it so I can do it myself ? Please help ( not by the Wizard ).Thank you
Good afternoon, I have a trading system that opens an initial trade based on some conditions and creates pending orders and moves the stop loss as each pending orders are become active or it closes. I'm running this on 2 currency pairs. It works perfectly until it opens a trade on both currency
Hi. I have a fragment of code in an indicator causing an issue with CopyBuffer in my EA. I have Googled and searched through the docs, they illustrate that this should work although I might have missed something. https://www.mql5.com/en/articles/599#convert_add_substract datetime now = TimeCurrent
please i am trying to create an ea that will draw two line starting from 22:00 GMT at night and to 02:00 GMT in early hour of the next day, the upper line will be the highest high among the four 1hour candles and the second will be the lowest low of the same four candles
Hi Everyone, My friends join this broker, they run EA on MAM/PAMM MT4 Platform But if you look closely at image attached, the trade lot size is not representing real trade . The trade shows It's open the trade with 21.70 lot size. But somehow It isnt, the real lot size traded is 54.24 lot in the
Good evening to all, I appeal to you because I have a problem with my code, indeed normally it must perform an order every 100 min: buy if the market is up or sell if it is down. The problem is that my code only executes sales, but it does not make purchases. I can’t figure out why he won’t buy
hi I write a EA that trading stocks how can i set the trading time to NYSE time ? That will auto update when the clock is move back or forward by the sesson
I want to double the volume as soon as balance doubles, I tried the following code OnTick but it doesn't change the volume even after balance is over 20000. I also understand that this code will keep on adding 2.5 to the volume every tick as long as balance stays above 20000. How do I write the code
Hi, what's missing in this EA, it does not trade, I have tried to make it work but without success. Christer
My question is simple: I have developed an EA that requires multiple indicators to work. When I upload all the necessary files in the mql5 marketplace, because I want to sell the EA in a single package, will the files be automatically packed in a single Expert Advisor file? Thanks in advance to
Hi, I'm coding an EA and I have this problem with a 2-dimensional array: when I backtest the EA the "array out of range" error pops up, can anyone help me please? input int LookBackPeriod= 10 ; //Look back period input int NumStds= 5 ; //Number of half stds int
Hi, I'm new to the forum so please excuse my mistakes if any in requesting answers to my query. I'm having issue in selecting the inputs while selecting optimization with "All Market Watch symbols" option. When I select a single symbol I'm perfectly able to select the input variables that need to
Though I close meta trader program after running automated trading experts, does it works properly
All i need is an EA to do the following; I place the Buy or Sell trade that EA has 3 Values for me to put my desired Inputs. Enable/Disable EA #1 Activate the Trailing Stop After X PIPS OR PROFIT Is reached. #2 Valve for how close to follow the current price from just like a normal Trailing stop
[Deleted]
Hi there, I have beeing with problems like "off quotes", if you have this problem very often (like me) its kind of annoying, but there seems to be a solution, and this is how i manage to solve it and actually finally allows me to manually close the orders i want to, still difficult to do it all very...
I am thinking to make a "concurrent" system that would have several EAs running simultaneously. And I thought it would consume less resources if some AE just won't run if they are not needed. But when that is needed another EA would have to run them ... So I've been looking at the documentation but
How to make sure function only runs at specified interval and not when its initially placed on chart
(3)
In the code below I run a function every H4. But the issue is when I put it on the chart it runs immediately for the first time before it starts running every 4 hours. How can I fix this code so it runs only when the chart 4 hour duration ends? Please note that I've only included the most relevant
Hi,im new in this lenguage, i have an idea for my EA, but i cat write it, i think it is basic but can u help me with a basics to can write it. im going to put de requirements of my EA: <Deleted>
Anyone knows whether there is an EA that can stop opening new order (but can close order and trail) for the coming week? paid or free. Please tell me. Something that I can input into a table for the close only mode period
Hi I am trying to use the MACD divergence indicator as a signal for my EA. In order to do this, I have tried to add another array into the indicator that stays at 0 and signals 1 when a divergence condition is met. I wanted to plot this array intially to see if it worked before using it in the EA. I
I have an EA which has been working for a month on a demo account. I recently tried to backtest the same interval to verify it with the live tradings from my account history and it is completely different. the data is the same and it is broker's data. What is wrong and how can I get the same
Hi, quite new to all this but when I try to drag my EA onto a chart, nothing attaches and I get an error "Cannot Load ......." Any help would be appreciated
Hello, I use multiple EAs and Currency Pair for trading for nearly a year. I have faced a difficult problem with News and suffer major loss. My EAs go to the wrong trend with martingale when News came. It happens the fourth times in the past year and It becomes my major source of loss. I wonder if
Hi Guys, I have been successfully trading a simple indicator lead system for sometime now with decent success. I am looking for someone to code it for me. The system consists of 3 versions of the same indicator that reference different timeframes. All 3 concur then take a trade in the direction
Last night, due to unknown reason my window corrupted and i can not boot my PC. I reinstall window and reinstall everything including MT4 and EA i purchased on the same PC. I lost 1 activation after that. Is it possible to regain my lost activation? The EA i purchased cost a couple thousand dollar
Hi, I have a binary file containing an array and my expert advisor needs to read it. However, I can't get it to open the file. I can open it with a script though. I think that the expert advisor is not looking for my file in the same folder as the script. I have put it in
Hello,
I am trying to get realtime ticks from mt5 to database Postgresql through dll and the problem is that when I try to apply my expert to few graph mt5 failed.
I use boost thread and boost mutex. Does mt5 support it? And how concurrency designed in mt5? Maybe mfc used?
Thanks...

You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
If you do not have an account, please register
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.