Download MetaTrader 5

MQL4 and MetaTrader 4 - page 475

To post a new topic, please log in or register
Does anyone here know why this only returns the highest value of the current chart loaded rather than the timeframe extern int TIMEFRAME=60;  HighVal=High[iHighest(NULL,TIMEFRAME,MODE_HIGH,MaxBarsBack,MinBarsBack)];//same as below  LowVal=Low[iLowest(NULL,TIMEFRAME,MODE_LOW,MaxBarsBack...
Hi, can anyone help?  This seems a simple task but it does not work. I want to start a buy process when Ask or Bid crosses a Bollinger Band for example; if(Ask==UpperBand)    // UpperBand is the iBands fuction { Then if ask is equal to Upperband then open trade etc .   The problem is that the double...
Hello, My problem is that I want to calculate lot size depending on the account balance like that: Lots2=(AccountBalance() * 0.001);Lots=NormalizeDouble((Lots2),1); But I wouldn't like to round the figure to the higher value so if my AccountBalance() is for example 10360 it's: 10360 * 0.001 = 10.36...
i tried to do the below   int updown (int timeframe, int shift){ if (  (iClose (NULL,timeframe,shift) - iOpen(NULL, timeframe,shift)) > 0)   updown = 1;   if ( (iClose (NULL,timeframe,shift) - iOpen(NULL, timeframe,shift)) < 0)   updown = -1;} basically if it's a function to give a 1 when the bar...
OrderSend(Symbol(), OP_BUYLIMIT,0.6,Ask-1*Point, 0, stopLoss, 2, "Buy Order", 0, TimeCurrent() + 60 * 60, Blue);   OrderSend(Symbol(), OP_SELLLIMIT, 0.6,Bid+2*Point, 0, stopLoss, 1, "Sell Order", 0, TimeCurrent() + 60 * 60, Maroon);  anyone can tell me what happen to these lines please?  They work...
Hi, I would like to creates an EA which find Gartley pattern and send order on market with proper stoploss ( X point) and TP (A point). GartleySearch search the pattern Gartley EA send the order My problem is that by using function iCustom () to GartleySearch indicator I can any get to know that...
Hello i have two emplye  can acces my account i want to get email if emplyee open or close order
Since a week ago non of my ea"s wants to work. My ea"s colour has changed to grey, and is unable to attached it to chart. In the expert folder it is saying the following: {2013.06.05 14:47:48 Cannot open file 'C:\Program Files\SIGTrader 4\experts\Boss Forexometro v1.1.6.ex4' on the EURUSD,M15}...
Can someone provide some information or give a link to a material that fully covers the subject?
Hi all, I've seen some code examples where the RefreshRates() followed by Sleep() is after, say OrderClose(). The question is where should be the right place to put it. Shouldn't it be before OrderSend(), OrderClose() or OrderModify(), instead of after ? Thanks in advance for any clarification....
I'm trying to use 2 demo accounts on one platform, but the chart windows always show same charts for both accounts. They do not switch.  
I'm working on a system that trades the US30 but I only want it to trade during hours the market is actually open, 09:30 to 16:00, I need something that can do this on current market and historically so I can back test. Is it possible to return the current time in the market of the instrument?...
Hi, Can anyone tell me how to find number of Open Trades? Thanks in advance.  -Krishna 
I just downloaded MT4 - Iphone version yesterday. However, after I registerred with Demo account, I only found the Forex item.   I was wondering where can I add the XAUUSD (Gold) into my list?    Thank you very much for your kind support.
l need help,l restored my computer,now lts not picking up my indicator on my mt4 platform.l have a good system l can share with anyone's help.
My EA has only up to one trade opened at any moment, but on certain bars it opens and closes mutliple trades, probably as many as the ticks in that bar. How can I prevent more than one or two trades opening in one bar?
  Why does this return 0? (16   1 2)
I am using the iSAR-Function in my EA. It is returning an accurate result. When, however, I try to add something, it returns 0: double SAR_C = iSAR(NULL,0,0.02,0.2,1)+0.00005; Print("SAR_C: "+SAR_C); This prints "SAR_C: 0.00000". Why is this? How can I prevent this/add something to the iSAR-Result?
i know c++ little and i know mql less than c++. how can i learn "building ea ?" is there any free guide or forum topic or link ?    pls help :) 
Hello, Right now, I use the "History Center" in MT4 for historical data.  GBPUSD H4 data only starts from the 2009.12.  Do you know where can I get data prior to that date?   Thank you, SC 
Hello,  I just joined the Forum and I'm trying to find a way to turn OFF this information box that keeps popping up and blocks information underneath it. I'm using MT4.  Image attached and also at this link: http://amson.org/images/MT4-INFO-BOX-1.jpg Thank you, Chris.   
Hello! I am looking for a way to insert a watermark to display in all my charts? Right now, i am using the "Text" function for a watermark that carries Ariel Bold font with a 225 size. However, it's not practical, as it is sometimes mistakenly highlighted and deleted during charting activities. Any...
I am moving here from thinkorswim (trying to anyways). I wrote a "strategy" I used pretty successfully there which I would eventually try to get set up as an EA over here, but first I obviously need my indicators set up. Below is what I have for trendnoisebalance indicator thus far, and below the...
Does it matter if I declare like this: int var;var++;  //Will it work,or do I need to assign zero to the var first like that?int var=0;var++;//Or it does not matter?Thank you.
New article The Random Sandbox has been published: The article includes an interactive "sandbox" as an Excel file which simulates randomized Expert Advisor backtest data. Readers can use this to help explore and more deeply understand the EA performance metrics offered by default with MetaTrader....
Hello. My English is bad. But I hope you understand my Problem.   I can not add the forexprediction.mq4 file (indicator) in any Chart in any Versions of different MT4 from any Brokers (MT4 from Admiral Markets, AVATrades, FXCM). The file is not crashed. Other user can it add to his Chart in MT4. I...
  Trade volume (1)
If I need a $1000 margin to trade at $10 per pip, how much margin do I need to trade at $1 per pip?
Hello Forum, I am attempting to put together an indicator that draws a horizontal line of fixed length  to the right of current price action at the level of the most recent high and low fractals, and also draws trendlines through the 2 most recent high fractal positions 2 most recent low fractal...
Hello, I need some help finishing the attached code! As you can see from the code it is a martingale EA which doubles the lots traded per successive trade until a win is achieved. I am a very amateur coder so please excuse the errors.  Please see attached code for additional details to the strategy....
From what I understand, there should be a smille face next to the expert advisor when it is dragged to the chart. When I drag the expert advisor to the chart, the expert advisor shows up on the chart but instead of a smille face showing next to it, there is an x next to it. How do I activeate live...
Hi everyone,   I have recently started trying to code with MT4 after using it for a few months and trying to get my head around the software. I have traded for a few years now and am really interested in creating my own EA's for backtesting/trading purposes, which i would also like to share on your...