Download MetaTrader 5

MQL4 and MetaTrader 4 - page 1067

To post a new topic, please log in or register
Hi all, trading on 4 pairs EUR/USD GBP/USD USD/JPY USDCHF EURUSDMaxLoss = -500 GBPUSDMaxLoss = -350 ... How can i calculate the MaxLoss on E/U and close all E/U trades if E/U MaxLoss >= -500 greater or equal if reached Example code can be combined for all 4 majors or seperated for each pair thx in...
Hello, As a programmer, it is frustrating when a new build comes out and the old experts/libraries/indicators cause crashing of the MT4 system. Is there any way to find out what changes have been made or how programs are saved in profiles, config, templates? So far, the only way I've found to...
I was wondering if someone can create this indicator? Thank you
Hi All, I would like to know how to use Expert Advisor & Strategy Tester options on MQL4 trading platform/system.....please help me. Thanks. Rupesh. Dubai
Hi, I'm working on a trailing stop EA, and for some reason I can't get the platform to compare numbers correctly, and it's driving me up the wall. Before trying to set a new SL value, I check to see if the new calculated SL is great than or lesser than the current SL, depending on it being a Buy or...
Is there any way to change the periodicity of a chart to something other than the presets eg 3 minutes? thanks
I am have difficulty compiling individual Include files. The main mq4 source file compiles error free but the individual Include files each produce varying numbers of "undefined variable" errors. I tried changing the undefined variable to Global types but most are local the the Include file and...
What I noticed that if an indicator is recompiled while still being attached to a chart, the line width specified via SetIndexStyle() is ignored inside init() and the default width is used (1). Here is the code, you can try it yourself: #property indicator_chart_window #property indicator_buffers 1...
can some help me to optimize this EA please
Hello everyone again! I am currently trying to figure out how to make my expert advisor open multiple orders at the same time, i.e. buying 1 contract, and then when account balance is high enough, opening two contracts at one price. This is all intended to be done on one chart, one currency. Is...
My EA does some processing as near as possible before market close each Friday evening. Up until now, I've programmed that to happen at 2255 CET (2155 GMT, 1655 EST). The first tick that happens after that time will trigger my Friday night processing. This has been working absolutely fine for ages....
Hi, im trying to do some optimization, by using a variable to input (close,open,low,high) for testing, but I get the unexpected token message, is this allowed? ======================================================== switch (valuefour) { case 0: value4="Close";break; case 1:...
i want to leran MQL from beginning. From where i will get books or vey very easy expert advisor samples, so i will learn how to write ea.
Anyone manually trading scalping successfully and tired of spendinghours in front of computer screen? Let me know, I will turn it into EA.No matter how complicated it is. One important note: it has to haverules. I am not able to code a discretionary system in which decisionsare based on intuition....
Attached are a screenshot and the source of an indicator written to show 4 Stochastic lines (of different periods - obviously). In practice, it compiles ok but it resolutely refuses to show more than one line - as shown in the screenshot (which also shows the periods it's set to display). Oddly,...
Hi All, I just want to know can we close the part of the order.. ie profit-booking of 50% of the holdings, when profit is 10 pips... Could someone please tell me how to achieve this... I tried doing.... OrderClose(ticket,NormalizeDouble(OrderLots()/2,2),Ask,3,Green); But I'm getting lot of...
i want to do something like this but dont know is it possible, i came up this idea cause it can save me alot time and lines for codiing int line(){int shift = 0;int shift2 = 0;int movement = 0;double redline(shift) = iCustom(Symbol(),0,"500",0,shift);double tealline(shift2) = iCustom(Symbol(),0...
I AM BLING IN N PROGARM, ASK FOR HELP I WOULD LIKE A PROGRAM, USE RSI SOURCE CODE PLUS ALERT WHEN RSI VALUE > " X " OR < " X ", SHOW ALERT WINDOW PRINT RSI VALUE " Y " AND SOUND " Z " TIMES EXAMPLE : WHEN RSI > 80 WINDOW SHOW RSI 80...
Hello,I started using the mt4 publisher on my own website. I'd like to be able to hide my account number like on mt4stats.com.How can I do this?Thanks,Stamat
I have an expert advisor which does trading automatically off the heiken ashi indicator, trading the euro/usd, I need help with to enforce the input parameters I have chosen for the expert advisor to trade by it self, the inputs are only half intact and not all features are working but as of yet I...
I've written an expert for MT4 that is giving ERR_OFF_QUOTES errors trying to modify an existing order. I place the order in the first step with OrderSend, and receive an acknowledgment that this was successful. I then try to modify the order for the StopLoss and Profit Target with what seem to me...
Hi there. I'm using the Heinek Asi smoothed (HAS) indicator to determan the buy / sell of the trates. At the moment I just use the following code. if (four_haOpen<four_haClose) {fourhourbuy=true;COL5=Blue;} else {fourhourbuy=false; COL5=Red;} if (one_hour_haOpen<one_hour_haClose)...
for example-: I have 3 buy orders and 4 sell orders open at the price below 3 Buy orders open price 2.5 2.3 2.6 4 Sell orders open price 1.6 1.2 1.1 1.5 Now I only want to display the highest of buy open price which is 2.6 and the lowest sell open price which is 1.1. Anybody know how to do this?
My company is looking into automation our expense claims. Anyone who is good at programming please write to me with quotation, further discussion could be arranged. Thank you.
Hi, I would actually like some expert advice as to why my color bar indicator chart [CZI] (bottom-most chart) always has gaps in between the transition of colors and/or loop onditions. I have attached the coding part below as well. ExtMapBuffer1 is coded with turquoise, ExtMapBuffer7 is coded with...
Hi All, I got an issue with the EA of RSI and MA... I got the indicator working properly... All I want is to convert it into EA... I tried a couple of things. IndicatorCounted() is not working in EA, so I tried to hard-code the values of the for loop (bar=0; bar<15; bar++), I was getting correct...
Dear traders and programmers, currently I am using MessageBox() to interact with the user. To distinguish different kinds of messages I want to use a particular background color for each message. The buttons are fairly simple though, I just plan on using one big OK-button. How to create MessageBoxes...
Hi, As a new mql programmer, I'm having trouble retreiving the original mql source code after a successful compilation has occured. The MetaEditor appears to only show a Template with empty header,init, deinit and start functions once the ex4 file has been generated. So far the only way I've been...
Hello All: I'm looking to perfect my entry signals for some technical signals in MQL4. For example, would the code below be correct for a buy signal when the Williams % R crosses above the -80 line [only included applicable piece of code]? williamsrcurrent = iWPR (NULL, 0, 50, 0);...