[Deleted]
Hi, I´ve been involved in Future and Forex trading for quite a while and started to like the idea of automating several things. I´m not talking about a completly automated EA as i think the human brain is still better in interpreting information correctly, but helping with screening software and,...
[Deleted]
how to get the order status for example,i want to get the condition if my order is purchased if (OrderSelect(_orderIdBuy, SELECT_BY_TICKET) == true) { if (OrderType()) { OrderModify(); break;...
When migrating to MT5, it would be a great time saver if a user could transfer all his code, profiles, templates etc. from MT4
[Deleted]
total = OrdersTotal(); for(i = 0; i <= total; i++) { OrderSelect(i, SELECT_BY_POS, MODE_TRADES); if(OrderMagicNumber() == 12321) { if (OrderType()==OP_BUY)OrderClose(OrderTicket(),OrderLots(),Bid,3,Green); if...
[Deleted]
I want to order a pending order, and every few miniutes later,I modify it as i am a beginner,would u to help me to show your code While (true){ OrderSend(Symbol(),OP_BUYSTOP, _number, Bid+_pendingPoint*Point,0,Bid+_pendingPoint*Point-_lossPoint*Point,Bid+_pendingPoint*Point+_getPoint*Point,...
[Deleted]
OrderSend(Symbol(),OP_BUYSTOP, _number, Bid+_pendingPoint*Point,0,Bid+_pendingPoint*Point-_lossPoint*Point,Bid+_pendingPoint*Point+_getPoint*Point, "some comment",16384,0,Green); 16384 ,what is the mean of this parameters? and the ordermagicnumber () magic is so difficult to understand.anyone to...
If I open a chart, say GPBUSD, how would I programatically be able to find that currency pair name? In my case, my EA will assign the MagicNumber based on what currency pair symbol exists on the chart I open. Possible? Thanks, Merlin
Hello, I have created an EA which I have done in C++. This produces the trades in a file, information stored is currency pair, buy or sell, stop loss and profit target. Is there an easy way for an EA in MQ4 to continuely read in from this file and when a trade is inserted into this file for the...
[Deleted]
Hi I am a developer who comes from a Java-background. Therefore I have a hard time understanding Array handling in MQL. Lets say I want to make an Indicator, in the calculation of the "current value", I need to know lets say the squareroot of some "earlier values", therefore I want an array with...
Hi Programmers! I have an EA and I'm working on the optimization. Sometimes, I choose more input parameters which cause big number of optimization variation. I run the optimization. Then, the tester of the MetaTrader shows the amount of the variation in brackets: Can somebody explain me what the
To: MT5 developers Found a bug for u guys it has to do with attempting to declare a Multidimensional Array MQL4 has a limit of 4 dimension MQL5 appears to have restrictions for local variable arrays but can declare much larger arrays in global declarations here: Everything is fine so far... but...
Different Brokers have Different quotes for EURUSD, such as EUR/USD, EUR.USD, and EURUSD2. So trying to use the market info function in the following way..... maxlots = MarketInfo("EURUSD",MODE_MAXLOT); won't return the value if you're using a broker that has a quote of say EUR.USD. Is there a way...
I have looked around, but cannot find quite the same problem elsewhere. If it does exist, please point me there... I am attempting to create a custom indicator which will return 3 possible values in a histogram: 1 - when I should be long 0 - when I should be out -1 - when I should be short. I have...
After making a couple of trades, and closing them out, history is not showing all of my trades, even after requesting to display all history. On top of that the history is not showing the price that a trade opened or closed at, it's very confusing, and lacking information.
How do I check through all already opened price? I tried the following, but does not work. if (condition)..... for(bcnt=btotal-1; bcnt >= 0; bcnt--) { OrderSelect(bcnt, SELECT_BY_POS, MODE_TRADES); if(OrderType()<=OP_SELL && OrderSymbol()==Symbol()) {...
[Deleted]
Hi all, I am wondering whether somebody could help me with an advice. I would like to create my own log, which would document trading related data for various sessions with my various EAs with various brokers. These logs are to be "aggregated", to be analyzed mainly by a program for various...
I get negative profit when running trailing stop loss because the code does not account for the commission and swap, I tried the followings which don't work need help, thanks! void LongTrailingStop() { int lcnt; int ltotal = OrdersTotal(); double BuyProfit; for(lcnt=ltotal-1; lcnt...
[Deleted]
I have programmed an EA and at certain pairs at certain timeframes it is profitable. I basically took the MT4 standard ea and changed the algorithm a bit, took out the lot sizing due to "130" errors. I can set a SL but I want the stoploss to go to breakeven as soon as I am X pips in the plus....
Can somebody please show me an example of how he/she used a buffer on a different buffer? so not the -standard- buffer on price case?
so if you have made a custom indicator, and at the end of your code file you have . . . Buffer[i] = something; } return(0); } But instead of applying this Buffer[i] on price bars, you want to calculate it on the values of a different iCustom indicator. How would you do that? Other_Buffer =...
What I am attempting to do is to take the current stop loss value calculate a percentage like 5% against it to get the pinch of increase I want to apply to the current stop loss to set my next target stop loss in a trailing stop loss. Formula: NewStopLoss = CurrentStopLoss * 0.05 +...
[Deleted]
Hy every clever people of this forum, I'm new. I've a strange behaviour of the programm in my EA. I want launch an order by Ordersend function, when "isCrossed" mets the conditions (1 or 2). But when I activate my EA only first case (in this example case 2) is running. In other words if I change my...
[Deleted]
I've noticed IsTradeContextBusy() one of the most commonly used functions is now no more in MQL5. Is there a new way to test if the expert advisor can execute an order or not? There are also other depreciated functions that do not have MQL5 equivalents. Those are: int ArrayDimension() int...
Is there any tools help to transform mql4 to mql5?
A PROFIT-MAKING/PROFIT ORIENTED STABLE EA IS NOT QUANTIFIABLE IN PRICE!
[Deleted]
Hi everybody, Maybe I'm blind but I can't find out how to change on object's name... Please let know! Thanks in advance. Dring.
hi community! can anyone help me with this error? i close an order with "orderclose", it works without any problems, on the same bar an new order is opened, also o.k., and then the EA tries to close the the same order again, it was closed before. of course now with the error output "unknown ticket"...
Dear Mr. Stringo: I used your ChartInChart.mq5 as an example for testing and evaluating my own EA in MQL5 platform called Trading.mq5 and advanced very well sofar. However I apply many EDIT Objects in an EURUSD-Chart and need to set data into those Edit Objects by means of a Button function on...
It's a simple EA code that brings this error ( '\end_of_program'-unbalance left parenthesis) at copilation) in line(136,4).I have try to check out for this error but I can't find ANY.Pls I need some help,I'm A newbie!I have attached the EA to this text
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.