Download MetaTrader 5

MQL4 and MetaTrader 4 - page 883

To post a new topic, please log in or register
static datetime Time0; int start() { bool newBar; newBar = Time[0] > Time0; if (newBar) Time0 = Time[0]; if (liHour == EndHour + GMToffset && newBar) more conditions here then open a buy or sell Return(0); } Does the above IF condition with AND clause work ?...
As a newcomer to automated trading (and this forum) I have worked out a simple 20 SMA / 10 SMA EA for which the MT4 tester has given promising results after several passages through the MT4 tester (on an Alpari MT4 platform): a 9500 euro gain over a period of 6 weeks for an initial deposit of 5000...
We are doing a major testing and optimization operation for our best Expert Advisors. Anyone who would be interested would be required to disclose their contact information, sign up for our forum, and they would then receive the EAs for testing. You would be able to keep the EAs for use, so long...
Hi @ all, i have for my Avatrader a very good Indicator to generate Buy and Sell Signals . Look at this link: http://www.actfx.com/Download50081.aspx But i need this Indicator for my MT4. Please can someone program it for MT4 ? This is the code for the Avatrader (.act):...
I would like to add some MA (about 3-4 MA) into it, if possible also include the MA prices, but I do not understand about the coding. thanks before
New article Creating Active Control Panels in MQL5 for Trading is published at mql5.com: The article covers the problem of development of active control panels in MQL5. Interface elements are managed by the event handling mechanism. Besides, the option of a flexible setup of control elements...
how do this script: example: GBP/USD no indicator lot:1 if BID above 1.4501 be LONG 1 lot, then if BID below 1.4501 close LONG and go SHORT 1lot (or vice versa). the script must always keep 1 open position(1lot) LONG or SHORT if BID is >1.4501 or <1.4501. thanks a lot.
Someone can help me, i was searching on google and forums... but i do not find anything. i need a script that it can place BUY and SELL orders with a hotkey.... i really apreciate your help on this!!
Hi, Has anyone managed to find a way to run its EA scripts in a shell under Unix/Linux rather that using the MT4 GUI (useless in deed on a VPS !!!) Thanks in advance Joan
Hi, Learning MQ4.. so need help on some basic things Following is what I need to find: 1. I need to find bar close price only when the bar is closed. 2. How do I identify the time in Mq4 in this format : HH:MM:SS ? 1) To achieve the first one - I coded like this,, does this really provide the...
  Divergent Bar (4)
Hi all, Does anybody know how to program a divergent bar (Bill Williams)? Basically I needto program 2 types of bars (candles) based on different time frames. The firstis the bullish divergent bar where the low price is lower than the previous barand the close price is within the top half between...
I simply want to stop program execution like Exit or Halt in other languages. How do I do this in mql4? I've tried return(0) as suggested, but it doesn't stop the EA, at least not in the Strategy Tester.
Hi. In first place, congratulations for Meta Quotes team for excellent work! I need to put each new order in non-repetitive price with previous ones. I can do easy with last order using "OrderOpenPrice()", but not with several orders. I want each new order to be in a price at least x pips distant...
Dear sir; I want to write a expert that when I open or close or modify orders at My MT4 Brokers, All change and affect send to my email or email Others. if(OrderSelect(1, SELECT_BY_TICKET)==true){SendMail("OrderTicket ",DoubleToStr(OrderTicket(),4)+"open time for the order 10...
Forget about writing stupid EAs. Just SELL EUROUSD at any level and one can make huge amount of cash. Since legendary George Soros has predicted EURO's eventual collapse a couple of months ago the EURO is now heading into the gutter. Greece and Portugal are already junked and Spain is on the brink...
How do send multi e-mail. example 1. aa@erer.com, aa1@erer.com, aa2@tr.net ....
I keep getting this error when optimizing: 2010.05.18 00:31:40 1999.10.14 13:55 uma test-3.1 USDCHF,H1: OrderClose error 138 I have deleted the history file and re downloaded it 3 times now here is the closing code: //close order routine...
I wonder if someone might help me with this problem I understand how to make a 1 dimensional counter array to count the amount of something like array[6] array[OrderType()]++ would count the amount of orders of each type there are while in a order_by_pos checking loop is it possible to make a 2...
int tempFun() { //---- static int temp=10; temp=temp+10; //---- return(temp); } //+------------------------------------------------------------------+ //| | //+------------------------------------------------------------------+ int start() { int temp=tempFun(); Print("the temp =",temp);...
Hello, If a trader just run the EA and it detects a trade signal but it is near the end signal where it is less favorable. How to program the EA so that it will not execute the first signal after launching?
  Volume versus contracts (12   1 2)
Maybe this question is silly for some but please bear with me. I know that Volume tick up means that there were more buyers than sellers. Is there any way to find out at least their percentage relation? What is contract in forex? How to understand the expression<<total volume bought and sold of a...
Greetings, Does anyone know where I can find a close all EA script ( open, closed ) orders. Sometimes i have a over 30-40 open orders running and I need a script to execute all Close on those open orders Thank You!
Hi, I am don't know anything about programing. But I was wondering if somebody had in there box a the script that would send an email ( or sms ) Alert when a bar Closes above and below a Simple Moving average indicator ? Thanks tradingkevin
  FAPTurbo (4)
The guys that created FAPTurbo just released their newest brainchild aiCashRobot. You cannot BUY this robot as they are not SELLING it! Instead of releasing the news of their new robot via all the thousands of affiliates out there, they rather embarked on something called referral marketing. This...
  Arrays? (2)
Iclaim to have read theBook [severalChapters severalTimes] & to havebeen reading theForum for some weeks [mostly, very informative/insightful Responses]. MyRequest is: Iset anExternal, then use it to define anArray as Global = theCompiler doesn't like it. What am i not understanding? ... extern...
I am developing an EA and have already programmed a number of tests for entry. When these tests give a Buy or Sell signal, I want to filter the signal through ADX. Here is the code I propose... bool ADX_filter(int type=0){   bool result=false;   double ADXminus = iADX(Symbol(),0,ADX,PRICE_OPEN...
Hello; I'm trading wit this EA, ILAN 1.4. But recently begun to show the next Message Error: "ERROR 0", and when this message arise the system don't let to set new positions. Do somebody knows how to avoid it?.
  error 4060 (3)
I got error 4060 which is Function is not confirmed but trade is OK or sometimes without indicator arrow. The EA makes trades upon arrow pop up but sometimes no arrow but it gets right value from buffer as is seen in Comment and makes trade. Very rarely yes arrow but no trade but shows good...
Hi there, I found out that I'm unable to run my experts before Feb 2008 on some (small) time frames, since the history is missing. On the other hand, it seems like there are many ticks, which makes me wonder whether it contradicts the above?
Could anybody tell me what it is about the code that means the overlaid lines do not exactly follow the WPR line? It isn't a major problem, but it all helps me learn mql4! #property indicator_separate_window#property indicator_maximum 0#property indicator_minimum -100#property indicator_buffers...