Download MetaTrader 5

MQL4 and MetaTrader 4 - page 1161

To post a new topic, please log in or register
New article Two-Stage Modification of Opened Positions is published: The two-stage approach allows you to avoidthe unnecessary closing and re-opening of positions in situations closeto the trend and in cases of possible occurrence of divirgence. Author: Genkov
How do I access more Forex charting currencies? I have 18 Forex currencies listed on my Meta Trader 4. My associate has 29 different currencies. Thanks, Fred
Hi, I'm trying to use the FTP function with metatrader but when I try to test it in the Publisher page, the platform cannot connect and return me following errors : 23:09:41 Publisher: starting 23:09:42 FTP: read answer error 23:09:42 FTP: login failed - 23:09:42 Publisher: error connecting to xxx...
Hi there, I've noticed some strange bar behaviour when MT4 terminal connects to the server after being disconnected for a period of time. I wrote a simple indicator to examine this behaviour that prints details of the last 5 bars in a chart every time the start() function is called. The output...
Francois Tremblay
  Wininet and assigment ? (18   1 2)
Hi all, I need some help - I'm trying to automate this process : Each day, I need to assign a new value to specific variables. I would like to upload a file on a server and that the expert advisor will be able to look for this file via internet and change the value of the variables with the new ones...
I can draw a rectangle fine, but what I'd like to do is have there be no fill in the rectangle, and just have the borders of the rectangle drawn. What OBJPROP would I need to call to set a border on a rectangle but have no fill? Thanks.
Hello I have a weird problem with an indicator I wrote that uses IBandonArray. When I first drag the indicator on the chart it doesnt work properly -- the values of ibandsonarray are not displayed at all. However if I recompile the indicator while it is still attached to the chart it will start to...
Hi, Can anybody help me understand that the following if statment is not working??? double Minimum = lowest of last N candles;int ShortRSI=X; if(iRSI(NULL,0,14,MODE_CLOSE,1)<=ShortRSI && Bid<Minimum ) { ticket=OrderSend(Symbol(),OP_SELL,................. If I remove && part of the...
I wish to utilize the same EA on many charts. Last week when I tested it, I had a condition whereby it would only place one order at a time. So if it was on two charts and the signal was generated, it would only place one of the two orders. So I modified it and now, I tested it over night and it...
Hello, When the timeline is set to D-1 (daily), when does the currency price indicated become permanent on the chart and not subject to being re-draw or updated? Background: Timeline set at D-1 (daily). Chart is set to line display and the momentum function is displayed. We wish to place a...
Hi there, I need to import external tick information (pricing) from a csv file to metatrader as an offline chart. I searched the forums and now I know is possible. My problem is that I want the offline chart to be updated automatically every 5 minutes with new info in the external csv file. Is this...
Hi, I am also one of the many people who are looking for a script to export indicator values to a .csv file. This is one of the things that should be standard in MT4. I'm convinced that the requirement to be able to program to really be able to use MT4 is not a good thing for 99% of the users....
Is there a limit for the number of else if statements? I am attempting to define a couple of vars depending on what currency the EA is placed on. I'm running into a mismatched { error and the position referred to is sporadic depending on where I place a function - it's not always in the same place....
Hello folks - Just wanted to know if there's a way to make a custom metatraderindicator into a "native" MT4 technical indicator. Instead of iCustom,i would like to make calls to iMyIndicator (like iRSI or iADX) instead. The reason is -making iCustom calls in an EA makes backtesting verrrrry...
(English Version) Can someone help me write code in MQL4 modifying the opened order? I have in my EA the following variables: takeprofit=100; stoploss=50; lots=0.1; current_price; //the current market rate price_of_opened_order; //the rate when the order was opened...
Is there any benefit to counting bars like this: for(i = limit; i >= 1; i--) or this for(i = 0; i <= limit; i++) ? Should I have all of my indicators counting bars the same way? Ifso, how do I convert it from counting bars using one method to theother. specifically from using ++ to using --?...
Hi all, I'm having some doubts abou the drawndown value. The maximal drawdown is the maximum "negative" value of one order, correct? How is calculated the Relative drawdown ? Thanks SB
Hello all, Anybody know about brokers that offer 0 (zero) spread acc. type? It must be registered broker company. Thanks in advance Best Regards, syanwar
I am completely new to MQL4. But trying to start using MQL4 for FOREX trading, I have an indicator I use in MetaStock, I call RSI-Swing. So, I need to convert it to MQL4. Trying to gain time is there anybody who could help? This is the MetaStock code: peri:=Input("RSI period: ",1,100,34); lbav...
Hi Is there any video lesson on how to creat EA available for new people who are starting out. Thanks.
Kind thanks, I'd like to know how I can apply pivot points to my charts.  Cheers Neil
  iHigh Problem (2)
Iam trying to adjust a trailing stop depending on the highest price in the past 90 periods.. and have tried this code, but am not getting a result. Can anyone point me in the right direction.. .......... thanks ...........Krakatoa double Trailer = iHigh(NULL, 0, iHighest(NULL,0,MODE_HIGH,90,1))*0...
Hi, I've been searching for a way to trade an expert advisor based on constant range bar charts. All I was able to find was this script: http://www.mqlservice.net/catalog/product_info.php?products_id=29 and I don't really want to pay for it... Has anyone here come across, or thought of developing a...
Hi, I have a strategy to backtest based on the last trading day. It means that I just needs the previous bar. I launch the tester and it starts to trade after 6 months whereas I know lots of trade should have occured before. It's like if this release includes a sort of minimum bars needed. Like if...
Would like some help translating two CTL strategies to MQL4 EAs, Please feel free to drop me a note shyguy_y2g@yahoo.com.
Currently I have set up three Moving Average indicators. (See attached) These indicatorsare standard MetaTrader 4 indicators, that I have attached to the chart using differenttimeframes. I'd like to be able to add these indicators to another chart, without having toadd them "manually" each time I...
Hello: What do I do if MetaTrader siezes up, after I had been trying to start strategy testing, I only run an EA on a demo account. It had never had a problem until I recently did the strategy testing that I'm certainly a novice at. Any help would be appreciated....
  Whats Wrong (5)
Hi All, whats wrong with this code. I just want to get long as the last bar closes above the last 20 bars, and RSI is above 14. extern int Quant_Bars=15; extern int LongRSI = 50; extern int ShortRSI = 50; extern double TakeProfit = 100; extern double Lots = 1;...
Hi I would like to manipulate a two dimention array with one row containing strings (ie symbol pairs) and the second row with an associated boolean state. I hope to link the boolean state of a condiction to a symbol pair. Many thks ronaldosim
  How to ... (3)
Hi! excuse for bad english How I can find Highest bettwen 12:05 - 14:10 in tester some day we have missing bars and when i wirte extern datetime T1=D'12:05'; MetaEditor give me some Errors I don t want to find for example T1=D'2008.06.01 12:05'; becuse this is for specfid day and not for...