MQL4 and MetaTrader 4 - page 62

To post a new topic, please log in or register
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 all, So i'm having issues passing the pair string input for an indicator im trying to use within EA. When using the indicator directly on a chart and entering the required symbols as inputs I have no issues and the indicator displays as expected, however when calling the indicator via iCustom the
I am more comfortable working with dark color bars on a white background. If I right-click on a chart and click "Properties", I have the option of changing to a different color scheme (in my case I prefer "Black on White"). However, I find myself having to do this for every new chart window that I...
  Terminal window missing (12   1 2)
I have been running MT4 on my laptop for several months. All of a sudden the terminal window won't appear? i have tried re-booting and several different profiles, no go. Any ideas will be greatly appreciated! Thanks, Steve
On Debian XFCE Buster Wine MT4 on both the Terminal and the MetaEditor we need to press ALT every once in a while bc the key gets "stuck" in a weird glitch. Anyone got a fix? Would be so great if they did a native AppImage https://appimage.org/
Does anyone know why if I run exactly the same backtesttwice (with the optimizer) the results, the order in which the passes are made ... and so on, are different? LAUNCH-A: LAUNCH-B
I am a beginner, would like to inquire coding EA Condition 1.After pin bar close price "+" 3 pin bar >>> open "Buy" order at pin bar 4(Open order at open price) 2.After pin bar close price "-" 3 pin bar >>> open "Sell" order at pin bar 4(Open order at open price) 3.EA open only 1 order per time and
how to get the account balance and equity to work in strategy tester ?Not the "real account", but in strategy tester. Looking for indicator that displays these values. Any reference is appreciated. Thank you
Dear Fellow-MQL-Afficionados! I started with MQL4 for about two months and have been carrying out some more orless successful experiments. However, I keep running into problems as soon as I try to use the function: iMAOnArray! In order to try to really understand this function I did some...
Does anyone by any chance have or know of a Profit/Loss alert indicator/EA, that would send an email alert when for example, Profit/Loss reaches -15 or any other custom negative number? Above an X amount would be nice also, but yeah
Hi all, Can someone help me with this indicator? I am using IC Market and mt4, but it seems to have an error. It wont create an ex4 file even if I already copied the indicator in the indicator folder of MT4. I have also restardet the program several times but to no avail. It seems to have an error
Dear community, i would like to announce new free software for the community. Its called "EASetup" and its able to create installation software for Expert Advisors, Indicators, Scripts, Sounds, DLL Files, Executable files and many more file types. Here is an overview about Features: Support of...
Trying to update EA which has already been installed on terminal (on my VPS so same terminal etc) and says it's going to use one of my activations any reason why
  Back test (2)
Due to the backtest by loading the data into MT4 and converting to different time periods. At first it was good but then later became n / a every time, so I would like to give suggestions for fixing
Hi All, I wrote a simple EA and back tested it and it game a loss. I tried to debug the EA by putting the good old Print statement. when I ran the EA again on the same currency and same period, the results turned to profit! just simple print, compile and then back test again and the whole result is
Hi all, When an indicator such as the "Awesome Oscillator" has an email notification in the input section how do I set up my Mt4 account and my email so the indicator will send me an email to my mobile when there is a signal line cross for instance. I don't want the ordinary alert for bids
Hi, I have created a bunch of EAs using Strategy Quant and am backtesting these in MT4 on a demo account. Originally, i wasnt getting any trades created at all and i checked the journal, it said there was not enough money on the account. I chucked in a million demo pounds and the trades were
Hi guys. when we change timeframe or close metatrader paltform, OnDeinit() function is called. I need to code whether timeframe is changed or Meta Trader is closed. Is there any way to check and distinguish this difference
Every time I try opening a trade mt4 says trade disabled please verify operation parameters and try again later
These 2 EA's execution speeds are very different, I take it due to the fact that in first one there is the declaration at top and in the second one there is only the declaration inside the OnTick() function. Is this all there's to it
I just found out about op_buy_limit and op_buy_stop. In my current understanding op_buy_limit and op_buy_stop fall under pending order, but it is listed as position that I have when I iterated OrdersTotal(). So this make me confuse about mechanic behind it. If I want to find out, just opened
Hi I'm a complete beginner on MQL4 but using what ive learnt so far, i've built an EA which puts a strategy ive developed into practice. However, after figuring out how to only trade once per bar, I realised that the trade only opens at the beginning of the candle eg. at 10:00 rather than when my
Hello all First I am sharing a code I wrote to format currency amounts with commas. Secondly I could not find this anywhere in the documentation but I'd like to simplify it. string sCurrency(string sIn){ bool bNegative=((double)sIn<0?true:false); if(bNegative){sIn=DoubleToString(MathAbs((double)sIn)...
Hi everyone, I'm not able to change separator when I create csv files, COMMA is always used as separator; I used the following: int Handle = FileOpen("fileName", FILE_CSV|FILE_WRITE, ); // CSV created with COMMA separatorint Handle = FileOpen("fileName"
I think it's just posible to make it by using OrderComment or so, but no idea about how to do it. This code close orders partially till exhausted: if(Bid>OrderOpenPrice()+(OrderTakeProfit()-Breakeven)*(PartialClose2/100)){
I'm looking to place an order once the stochastic %K is below 20, the slow ma is over the fast ma, then check for an additional condition for the stochastic. If this occurs I want the for loop to look back "i." number of barsback to see if an additional condition occurs within that range. Can
Hi, I m using MetaTrader4 Administrator to send reports to my clients. However, i couldn't send reports to "Gmail" accounts. It gives an errror message. Is there any way to send reports to "Gmail" account. How should fill in the "smtpservername" for "Gmail" account. Thanks in advance, Balaji G
Hi, I am learning to code. Wrote this EA to call an indicator. It works fine. But, in 'Print' on a down trend, iCustom_1 returns an EMPTY_VALUE and on an up trend, iCustom_2 returns an EMPTY_VALUE. Could someone tell me what I've done wrong. Thank you for the advice in advance. Harvey_Trading
  Is <11 faster than <=10? (79   1 2 3 4 5 ... 7 8)
<11 faster than <=10? for example if(b>0 && b<11) vs  if(b>0 && b<=10) Is the first one faster bc its just one thing < vs <=? Worth it?
do you guys have the adx indicator to show on the chart as the value of the adx ? just as a number i mean ,on the chart ..without having the adx open below the chart