Download MetaTrader 5

MQL4 and MetaTrader 4 - page 9

To post a new topic, please log in or register
Hello Wouldsomeone be able to help me to amend my script? I would like to be able to movethe arrow signals from the folder ‘parameters’ to the ‘colors’ folder. I attachscreenshots showing what I mean (no. 1 how it is currently, no. 2 – how itshould be after moving): I wouldonly like to move the...
hi , I wanted to know if it is possible to get History Base : X errors in pair "abcXYZ"  I think metatrader checks history while rendering chart and generate error in a seperate process than EAs. its not some error code that can be accessed via GetLastError() in mql? I want to know if metatrader...
  global initialization failed!!!!!!! (64   1 2 3 4 5 6 7)
If anyone could help...I run an expert advisor for 4 chart pairs, and for running it for the 5th, after loading succesfully, i have global initialization failed, and then removed... I would appreciate at least a guidance what to look for.. Thanks...
Hi I am just starting with mql4 and playing around with the code, trying to print the low of the bar but only if it is a lower than the lowest value in the current bar. Any idea what my code is not working? Thanks The following code is #property indicator_chart_window#property indicator_buffers...
I am in the early stages of learning how to code custom indicators and haven't got a clue what these refer to. I am trying to code an ATR stops indicator and am referencing one I have downloaded which has 5 buffers, 3 of which are 'smin', 'smax' and 'trend'.  I just have no idea what these are and...
Hi, I have objects that i display with different timeframe visibility on the chart as such so that i don't clutter the objects onto higher timeframes.            ObjectSetInteger(0,sObjName,OBJPROP_TIMEFRAMES,OBJ_PERIOD_M1|OBJ_PERIOD_M5|OBJ_PERIOD_M15); Now i want to retrieve the objects and find...
Hello Gents.. I am completely baffled at how to properly get tick data set up to in MT4 backtest my simple EA. I wish to get about only 6 months worth of EURUSD tick data to do some accurate backtesting, and I basically followed the instructions found here: https://forums.babypips...
Hello my friends, I'm programming an EA on MT4 and it seems to work very well but I have some troubles when testing. I can not see opened positions and balance... It is frustrating because I can't see how much is my balance, equity and profit. I tried to show balance within code but it does not show...
Hello, there is a major problem in the "period converter". Depending on the period and the multiplication factor, the script does not convert some of the latest bars. For example, if we make a conversion from 1H to 3H and now we are in the "hour 2", this bar is not converted. Any solution? Thank you
Can someone help me to solver this error!
Hello Everyone, How can I remove this part of my code and still have it working double IMA()  {   iMA_Close= iMA(Security,Timeframe,ma_period,MA_Shift,MODE_SMMA,PRICE_CLOSE,SHIFT);   iMA_Open = iMA(Security,Timeframe,ma_period,MA_Shift,MODE_SMMA,PRICE_OPEN,SHIFT);   high = fmax(iMA_Close...
Dear support,Any ea and indicator for android device at mt4..? Tq.
hi i want script for my custom ea to open a website as soon as the ea is attached to the chart please help
Hi, this EA is basic but useful to me, its restriction is it will only monitor the order that corresponds to the chart it is attached to. It is designed to partial close at first TP level then step trail SL but no more partial close. Is it possible for the EA to monitor ALL open orders and apply the...
Hi guys, I'm trying to calculate a moving average over momentum indicator but EA crash at the boot of the back test because of the buffer I think ... someone has a better idea how to solve this ... I'm trying to calculate the moving average in the wrong way i think... //--- Get MOMENTUM and...
I was looking for information on how to write a timer correctly on the net. And I found this EA based on RSI on more markets at a time. I was intrigued by the "do it anywhere else" Unfortunately, EA can not test anything. Can EA be written on more markets? Thank you....
Good afternoon you all, I have this Expert Advisor in which I can set take profit and stop loss in points. I want to change this parameter with the percentage of the investiment. For example, when the profit is at 25% of the amount invested or when the loss is at -70% of the amount invested the...
Is there a function, in MT4, that I can use to grab any pair that is listed int eh Market Watch window?  I'm trying to make a combo box and I want to be able to select any pair, in any Brokerage account, and not have to manually insert the symbol.  With _symbol or Symbol(), I have to manually input...
  Code for risk per trade? (24   1 2 3)
Hello, I have coded my first EA and I am looking for the code that will open lot sizes at a percentage of my account. Can anyone help please?
Hi, I can not install other templates and indicators from the web on my MT4 platform. I specify that these files are in EX4 and MQL4 format. I followed the installation procedure by going to File / Open data folder / MQL4. I even uninstall and reinstall the app many times. I receive as error message...
Simple question here regarding the ATR indicator: I feel a little handicapped this way. I want to see the exact value.. not just guessing. I do not want to grab the cross all the time to check. It will take to much time and makes me entering a trade to late. I need that value because i base my...
Good day Everyone, I have a custom made indicator that draws Red/Blue arrow when CCI cross the ZERO LINE. What I want is that the arrow are drawn far away so that i can see the High/Low of the candlestick. I want it to look like the Yellow/Green arrows. How will I do? I know it involves programming...
Hello MQL community, I just started to learn the MQL language and I am currently trying to build my first EA. So in my first EA I want to only do a CALL or PUT when the fractal+diamond occurred two candlesticks apart (See image for example)    If the Fractal (the yingyang symbol is green) The Value...
Hi, I am trying to learn how to create a simple robot. Basically as an example I want it to buy when the daily price closes above a MA (144 as example) and then close when the closing prices closes Below the MA, but when I test it I don't get any trades and I get the following 2018.05.24 16:24:56...
Does anyone out there have a clue on how to get this to work, inside a CAppDiolog box?  I'm trying to make several dialog boxes, inside a main dashboard box, but I need to get the main Dashboard to scroll up and down.  Does anyone know how this thing works?  When I put my smaller dialog boxes inside...
  Get Computer Name in mql4 (24   1 2 3)
Hi, I want to get computer name in mql4 in order to make original log file including computer name which MetaTrader runs. I think it is possible using GetComputerName function in kernel32.dll, but I don't know how to implement it in mql4. I found a kernel32 api example and modified it, but it...
Where is the best place to put this code? Now I put in the OnTick() function but if disconnected(internet) calling OnTick() does not occur! Which function mql4 call every 1 second? if(!IsConnected(){     Print("No connection!");}
hello , can any one help ?   i have an indicator in seperate window, i want modify it so it can load on main chart window .
All of a sudden one of my FFCal news indicators is giving this error in build 1080 using the EventSetTimer function. It worked perfectly fine in previous builds, was there something change that I am missing?
Hi! Would like to ask for your opinions and comments on the structure of the following code.  My main concerns are as on the: 1. The code is a template. The specifics of Open & Close conditions are negligible. So are the values of extern variables. My main goal is to create a template where I can...