Download MetaTrader 5

MQL4 and MetaTrader 4 - page 511

To post a new topic, please log in or register
Hi all,  I want to get the OrderCommission() of an open order, for that have include extra code in the following block, Is this right and if so is it  value accessible in any part of code including void functions if I put double Commission; in Global ?  Thanks in advance for any help provided. Luis...
Seeking help; Live MT4 account stated in notional unit size (ie, instead of 1 lot, trades stated as 100K). However, when programming in strategy to backtest,  MT4 states "Lot Size." Thus, when backtesting, if I put in 1.0 in "Lot Size" (for 100K units) it is being read as 1.0 units instead of 100K...
Hi. I need help modifying an EA that I paid to have coded. It is a basic fractal breakout EA with trailing stop and breakeven, TP and SL. I want to modify it such that, once a fractal is used as a signal to open a trade, another trade will not be opened based on the same fractal. This is to prevent...
Hi guys, I'm just wondering if there's a way to do something like a fill-or-kill with two pending orders - so that if one couldn't be filled, the other wouldn't either? I suspect not. In that case, is there a way to bias the likelihood of two pending orders being filled in my favour? There is a buy...
I'm working on a new EA, and have created a flow chart to visually show how it will work, and it hit me.....what happens if for whatever reason, there is a communications failure between the client (my pc) and the server while the EA is running and there are existing orders already placed?  Here's...
Hello forum, I am not quite sure of the right wording for this question. I have made an indicator that draws arrows on my chart during the current (0) bar for certain conditions. This is what I want it to do. But I am wondering if it is possible to remove the arrows at the end of that bar. I only...
hi pl guide me i have fapturbo robot which time frame to select 1 min 5 min 15 min .what sl and tp in pips to be placed and lot size
Hello, I want to trade up (add to position) with a trailing gap after a certain amount of pips but only ONE trade up order as the trade up distance is reached. E.g. place buy order - first order at +50 pips trade up trailing with trailing gap - new trade up order (the EA currently places multiple...
Hey All, I have no programing experience, but recently started playing with Forex Generator 4 to create an EA. It is a fantastic program and I have pretty much included all the conditions of the manual strategy that I am trying to automate, except for the ZigZag. Is it posible to incorporate ZigZag...
Why do I often get OrderModify Error 3 (ERR_INVALID_TRADE_PARAMETERS) in such cases? 2013.02.11 01:39:53 - StopLevel = 0.00020000 2013.02.11 01:39:53 - FreezeLevel = 0.00000000 2013.02.11 01:39:53 - Error Modifying Sell Stop: 3 2013.02.11 01:39:53 - FROM: Entry = 1.33226 SL = 1.33684 TP = 1.32695 ->...
I've coded this little indicator to show me the last 10 trades profit or loss in pips. At the moment it shows me the first 10 trades in the order history pool. I want to display the last 10 trades. I can't work out why it won't work, can anyone help? Thanks.   double orderpipsprofit;color...
Hi all,   Is that possible to call a function from another function. What I mean is, if inside a void function I want to call another void function is this possible ?   thanks for any clue here Luis 
hello all .. I do not understand programming,,, help me,, this indicator who's willing to make an EA? .. is a good indicator in use TF M15, I would like this indicator into an EA,, thank <DECOMPILED (stolen) CODE REMOVED ! !> 
XXXXXXXX is a valuable indicator .It's a trend indicator and show the acceleration of the trend (Uptrend or downtrend) . How does it work ?
profitorig+=OrderProfit()-OrderCommission();gives 59.51 + 7.37 = 66.88 WRONGprofitorig+=(OrderProfit()-OrderCommission());gives 59.51 + 7.37 = 66.88 WRONGprofitorig+= MathAbs ( OrderProfit()-OrderCommission() );gives59.51 + 7.37 = 66.88 WRONGprofitorig+= (OrderProfit()-MathAbs...
I need some understanding on how some of you who run many ClientTerminals - all same expert and some/all using same account# deal with eg, daily draw down limit, maximum money risk, ... On single Client, one way to deal with each expert's 'slice of the money cake' if 2 or more on same...
Hello everyone, I have currently compiled an EA and have all the errors taken care of. When compiled I can use it on my chart via MT4 but I cannot send the file to another, and I do not have a exe. How do I create and exe. file from this mq4? I though compiling did it automatically. Thank you for...
Hi,  I'm writing an excel macro to send email from Outlook. Can I set the "From" id from which the email is sent? I tried using the following code. but it dosent work:    With OutMail         .SentOnBehalfOfName = email@email.com         .From = email@email.com End With  Regards, Nitin     
New article Change Expert Advisor Parameters From the User Panel "On the Fly" is published at MQL5.com: When developing complex Expert Advisors, the number of external parameters can be very large. And settings very often need to be changed manually, making the whole process very time-consuming,...
I AM FROM INDIA INTRESTED IN DESIGNING EA ON DAILY TIMEFRRAME GIVING LEE TRADES WHAT SHOULD BE A STOPLOSS FOR EURUSD ATTACHED IS EA
I am looking for golden sectionn oscillator.If anyone has any info regarding it please that info will be helpfel.Am needing it as it will be simple to execute an EA based on the oscillation.It seems very difficult to understand from the original golden section indicator as it is crowded with lines....
// check if lines have crossed   if( ma7 > ma14 && ma7 > ma21  && ma7 > ma49 && ma7 > ma70 ) siCurrentDirection = 1; //up   if(ma7 < ma14 && ma7 < ma21  && ma7 < ma49 && ma7 < ma70  ) siCurrentDirection = 2; //down        if( ma7 > ma70 ) OrderClose(OrderTicket(),OrderLots(),Bid,3,White);...
Why do I get ordersend error 130 when i backtest my EA?
Hello: I'm trying to automate certain parts of a strategy that I'm doing visually with good success.  Essentially I'm trying to superimpose one currency on top of another.  For example, GBP/USD on top of EUR/USD.  If the currencies both traded between the 1.40 to 1.60 this would be easier, however,...
if possible may see a comments of closed orders, what would the script ?
I hope MetaQuotes update mq4.com to mobile version like mq5.com
Hello Forum I want my indicator buffers to show the historic levels that a certain set of conditions have occurred. In the past I have just used arrows (DRAW_ARROW and an appropriate wingding code) to show the bar in which the conditions occurred the manually went in and worked out the price level...
I want to keep my view on the "Trade" tab/window but everytime I get something in the "mailbox" tab/window it just automatically switches to it,...... then I have to click on the Trade tab again to see how my trades are going........ Is there a way to stop this from happening and gets quite...
Hi everybody, I'm a beginner with automated trading. I hope to have your help because I'm stuck. I'm trying to convert this indicator to EA. This is a breakout strategy based on an interval in hours. My code does not work, it does not respect the buy signal ps: sorry for my English, I'm French...
Hi all,   I have a hedging EA and cannot seem to hedge at market price because the sell order closes the buy.   Hedging works fine on pending orders, both can open with different stops and take profits.