Download MetaTrader 5

MQL4 and MetaTrader 4 - page 18

To post a new topic, please log in or register
I am making an indicator to identify tops and bottoms of price movement and connect them just like the zigzag indicator actually there are three buffers: tops[] , bottoms[],and zigzag[] which is the combination of tops and bottoms my problem is that sometimes the same candle  qualifies to be have a...
Something strange overhere, only when i close and restart the metatrader 4 platform orders from my EA are placed, immediately.. Has it something to do with connection, or with the EA, but what? Ed
I know this has to have been answered before, but I can't find it in the forums... So on with it. How do I make my indicator update every tick? I have an indicator that draws an arrow above and below a candle that is an inside bar. The problem is that when a new candle forms, it is an inside bar,...
IndicatorCounted() - Which are the Default or Correct indicator calculation in MT4/MT5: Current data to Previous data ("Right to Left" or "Zero to Last bar")??  Someone said that if you started in current data ("0") for indicator calculation then your indicator become lagging indicator?? WTF! I...
Hello, the shortcut for commenting (blocks of) code in MetaEditor is "Ctrl + ' " (both on PC and Mac) However, the PC-shortcut for uncommenting is "Ctrl + ; ", but that doesn't work on my Mac. Does anybody know the shortcut for uncommenting (blocks of) code on Mac? Many thanks!
Am starting to experiment with EAs and custom indicators and would like to know if there is a fast way to 'comment-out' (//) in one go code that is selected in MetaEditor. Figure there must be, but have been unable to find the solution so far. Thanks in advance for any help.
Hi, I'm Newbie of coding. Copy, Paste and edit is my Practice now, i facing some problem hope you guys can help me. Please help to solve the error as below. Thanks 'Verbose' - variable not defined  Utility Functions //=============================================================================...
hi, sorry for bad englih, I have one expert advisor, but backtest is very slow, in robot code have my indicator code, (in this way my robot not need indicator for use) but I thin this is not reason for slow backtest ( because I delete my indicator in robot code, so in this way for my robot use need...
[Help] Custom RSI is Missing Some Portion of Indicator Lines in 4-Hour timeframe (GBPUSD). I used SMA to get average gain/lose instead of Wilder's SMMA the default mode in MT4/MT5. If I used SMMA then everything works as expected but If I use SMA then some portion of lines is missing. I can't figure...
Hello! ‌‌Recently my MetaTrader 4 Market tab inside the Terminal window stopped working properly. Every Market tab (Main, Favorites, Purchased) shows a blank white screen. The same thing goes for all of my platforms running MetaTrader 4 version 4.00 build 1045 (3 Feb 2017). I have tried restarting...
Hi guys!  I was looking for an automatic lot size calculator based on a horizontal line. All the stuff I have found are position size calculators, but then you have to manually enter the lot number in the Red/blue chart with the buy/sell buttons. I need something that automatically calculate the lot...
Hello, I'm learning a few programming languages, including MQL4, and I came up with a question that I didn't managed to find the answer on reference guides.When you define a new function, lets say a simple one: Double Product_3Numbers (double x, double y, double z){Result= x*y*z;Return(result);}What...
hi all, I found an helpful free Expert which closes orders after a set time, unfortunately it delete too pending orders! I would like it to close only the opened trade. Someone know how to solve this problem changing the code? thanks
Hi, I am working on a trading systems based on MAs and Sup/Res levels. The idea is if án MA and SUP/RES are very close to each other and price touches that level and bounces back to open an order. One could code that like this: if(low < MA && low < RES level && close > MA && close > RES level)...
Hello everybody, Sorry but i m newbie... I would like to create a simple EA based indicator Dtosc: BUY cross <30 SELL cross >70 I start with indicator but I can't turn it into an EA. Please, can someone kindly show me what are the first steps? This is wrong: if (SD > SK ) {...
At the very first I know that this thread is about MQL5 and I've attached MQL4 code but I think this problem is the same in MQL4 or MQL5 (maybe I'm wrong). EDIT: I've tried in MQL5 and this problem doesn't exist in MQL5 I create (by code) several objects on the chart and the first one is clearly...
Hi, Since I use Android 8 I face some serious problems with the Metatrader4 app. Every time I switch from a randon tab to the 2nd tab (graph) the app quits and I need to restart. I'm using the latest version version of the app (400.1102) and Android 8 on a new Huawei P Smart. I tried already to...
Hello guys, I'm a bit stumped here. I have developed an EA to trade Bollinger Bands. Any of you who have seen my previous topics know I'm new to coding, but I feel like I'm making progress. The issue I'm having is that when running an optimization on this EA, I get a "Zero Divide" error. This error...
Hi guys, is it possible to send trade signals to mt4 via ideally telegram? or sms or email?
Hi, When debugging EA's, you have the handy-dandy Expert tab to send Print() output to. Is there an equivalent way to easily output values when debugging indicators? Cheers and thanks.
I cannot seem to find an option on how to change the time. The candles are 2 hours in advance. When I installed MT4 I was in a different country that was 2 hours ahead. Is there an option to change the time, I wouldnt want to reinstall MT4
Hello I need a help how to lock my EA/Script based on my login account number ? example: my login number in my broker is 12345 , and I want my EA/Script can run only inthat login number. also how to lock the EA/Script that can run in one broker only ? (example: my EA/Script can run only in...
  Requests & Ideas, the beginning (2710   1 2 3 4 5 ... 270 271)
i test some EA at my server here is the best combination that i found firebird at usdjpy M30 hans_ea3 at gbpusd H1 note for statements, fxindo-nf3 is my own EA, i have de-activated it. so please ignore it. it made around 180 pips for last week... update : sorry, i've attached wrong statement.......
I need a help how to lock my EA/Script based on my login account name ? how to make the this script can run only account name of jeo mex for the example ? 
I planned an EA trading with grid.i explained grid like this: bool buypoints(){double m[201];for(int k=0;k<=200;k++){m[k]=NormalizeDouble(((uppervalue*1000-steppips*(k+1))/1000),Digits());//uppervalue and steppips are external values for usd/jpy.if(m[k]==Ask) return(1);}} if (buypoints()&&some...
Is it possible to apply custom indicators to mobile metatrader? Is there anyway at all to import custom indicator into MetaTrader 4 Mobile? As far as I know you can't, but I was wondering if there have been any updates or custom updates that allow custom indi? If can, How can I load custom...
I use current month+ current day+account number as a seed for MathSrand() to generate a pseudo-random magic number each day. I would want to be able to look at trade history and create a report of all trades that hit SL (for example), so I would want to get a new seed for each day in history to be...
Is there a method to capture an objects name from the cursor position? All i seen to be able to capture is the price and time I was thinking something along the lines of placing the cursor at Time1 and Price1 and then iterating through all the chart objects until I find a match for Time1 and Price1...
Hi i`m trying to build a trailing stop, and it's working fine but sometimes i get a nasty order modify error 1.I don't know if it's harmful i've read the documentation it is when the value is unchanged i guess,but the question is how to resolve it :D .Hew is my code: double TRAILSTOP;extern int...
  Excel bridge (4)
Is anyone aware of a MT4 script which would read from and write to Excel?   I know that there's one product easily found with googling.   But the reviews aren't that great.  I can get python or other code written for this but I assume someone else already has the pieces. Thanks