Download MetaTrader 5

MQL4 and MetaTrader 4 - page 261

To post a new topic, please log in or register
I recently started to use the strategy tester, on MT4 version 4 build 840. I have tried to find an answer to my problem by searching the forum and the web, but no results. I hope that someone here will be able to at least direct my research. The data returned by the Print function in the strategy...
Hi all,   I am trying to write an EA but I am having problems opening a trade and closing a trade on the next bar after a signal using icustom. Can someone point our my errors and how to fix them. Only one trade in any direction at any one time. Thanks in advance. 
New article Using Layouts and Containers for GUI Controls: The CBox Class has been published on mql5.com: This article presents an alternative method of GUI creation based on layouts and containers, using one layout manager — the CBox class. The CBox class is an auxiliary control that acts as a...
Hi Guys! Im currently developing an EA System and would like some help on a certain thing. Basically the idea behind this system is that it will open a trade and wait for the price to rise and if the price drops by two ticks from the High of the current bar it will close the trade and then open...
In my indicator I change in OnCalculate the values of the buffer of the last 10 candles. MT4 always shows the old values values for the past candles, not the new values; only the value of the current candle is constantly refreshed. I added a call to WindowRedraw() after the buffer is updated but...
Everytime I load a custom indicator instead to see arrows or symbols, I see that letters. How can I solve this problem?
I read about the WindowScreenShot but I can't guess how to use it to print the historical charts .Say I want to use 15 min time frame and  print the last 20 days  charts .Every day to a .gif file .Any help ? 
Hello to all, for about two months I discovered the world of binary operations. I downloaded MT4 and I tried to understand the workings of the candles. I noticed that often after a candle long the trend will change within 15-20 minutes. Taking a currency as an example, this happens at a rate of...
Hi, I have been working on an EA and want to try it out with a live account for the first time ever. Do you have any tips or check points that can be good to look at (that easily can be missed). The simulator test seem to work fine and currently the EA is running on a demo account. BR Michael 
hey every one   mt4 plateform perform back testing on chart's history bar data or it performs back testing on tick data Many thanks  
consider a certain value being used by an EA (e.g. a profit target) int h=3;void OnTick()  {Comment("Value H = ",h);}  Now let's say: if i want to change the value of 'h' during EA running, i would ideally simply want to do a little script like this: #property show_inputs input int h=5;void...
You can see that the latest version of TickStory v1.6 isn't free any more.  The script, CSV2FXT, downloaded from EareView can't work in the latest version of MT4. Now, how can we make the back test with good quality from now on? I downloaded EurUsd M1 data from DukasCopy. If using the script,...
How do I add something of a "separator" or "header" to visually separate different Input parameters in the Expert Properties of an EA?   V 
I have seen for loop here works tick wise. How to run the loop bar wise?  I want to add +1 pip from the low in per bar in 1 minute chart. I am creating Gann 1x1 Angles, where for each bar angle will rise +1 pip upto 120 bars.  if( LowT < HighT)  // If low formed first {     datetime i;     for( i =...
I would like to include a similar type of object drawing on my charts for my EA so I can visually track when and where it opened and exited trades... anybody has or know where to find the code strategy tester is using?
Is anyone else having problems with the Print() not working with a Demo or Real Account in Build 840 ? It works fine in the Tester and worked perfectly with other builds but in the journal this is all I get ... 0    14:51:49.584    '8735210': close order #178077577 sell 10.0 EURUSD at 1.10581 sl: 0...
Alphabetic Index of MQL4 Functions - MQL4 forum (2009.12.18 08:55) updated for Build 600+ AccountBalanceFileFindFirstIsExpertEnabledSendFTPAccountCompanyFileFindNextIsLibrariesAllowedSendMailAccountCreditFileFlushIsOptimizationSendNotificationAccountCurrencyFileGetIntegerIsStoppedSetIndexArrowAc...
Hi, I like to get candles highs & lows to calculate mfe&mae. I have written a script wich is getiing trade infos from history after magic number and symbol. The script is working properly until the code arrives to get the candle highs&lows. Here is the code, I have a problem with for ... I am...
After I read differences among MM, STP and ECN on the internet, I am more confused now except knowing there are mainly 3 types of accounts that are MM, STP and ECN. How to distinguish them simply and correctly? May I understand ECN>STP>MM ('>' here means 'better than')? Moreover, how do I know my...
Name brokers and  how price fraud.
Hello, I have a problem with a metatrader 4. The problem is, that prices compared to the metatrader 5 are different and also the price movement is different. The correct prices are in metatrader 5 which I use more, but few signals that I'm trying to use are in metatrader 4. Does anybody had that...
Hi  Apologies if these scripts are very easy to find, I've had a look around and had no luck so thought I'd try the forum. I'm writing an application in MVC to help me with my trading, and I need a script to use in MT4 that can read a text file that my application will dump out and create and close...
Hi Guys, whats wrong with the new MT4 setup? I cannot choose the installation folder for MT4. We have so many mt4 upgrades. With the new setup we are not able to install the MT4. The default installation under C:\programs\MetaQuotes ist not allowed, its a server-rule. Please help me. We need the old...
Hello.  I am thinking on a multi timeframe EA that uses indicator called parabolic_r2 (modified parabolic SAR) with the following code void Parabolic(int TimeFrame, double& Buffer[],double& BufferUnit[])//_counts_parabolic_r2_for_all_TFs{  int j=1;  double d_step, d_High, d_Low, CL1;  //if...
Hi,  if i open a file for writing in the OnInit, use a timer to write, then close the file OnDeInit, is there anyway i can view file (read-only) during EA run? i keep getting:  "<file>.csv cannot be accessed. The file may bcorrupted, located on a server that is not responding, or read-only." int...
Hi,    May i know if the strategy tester for MT4 includes interest rate calculations when testing a strategy? Im using oanda as the broker. Thanks. 
Formula for CFD to get margin , do not understand how to get Percentage with function ? Margin: Lots * ContractSize * MarketPrice * Percentage/100 If I use MarketInfo(Symbol(), MODE_MARGINREQUIRED) Then if pair is type: Forex (0) MarketInfo(symbol, MODE_MARGINCALCMODE) its output sum in dollars, but...
Hello, Is it possible to show news from providers like Bloomberg, Dow Jones, Market News International, or WBP Online directly in my MT4 platform?  Is it for free or how much do I have to pay for quality news feed?   Thank you. 
I am sorry if I am posting to the wrong place.  I am a heavy user for MT4. I am managing many accounts.  I need to re-install whole environments to new Windows frequently. Is there any option to install (or uninstall) MT4 automatically? (silent install, or command line installation mode, etc) For...
Hello,   I'm using a lot size calculator script and I'm trying to "enable live trading" for it.  I can enable it from the tool, but I don't want to have to manually do it every time.  In the install video they show a global setting that can be ticked  from TOOLS>Expert Advisors tab.  The problem is...