MQL4 and MetaTrader 4 - page 395

To post a new topic, please log in or register
Hi everybody, I am wondering if SendNotification() is possible from indicators. The MQL help https://docs.mql4.com/common/sendnotification tells nothing about that. But the MT4 terminal Options menu tells that push can be sent from EAs and scripts. If you know the answer please comment, thanks.
Is there an easier way to find the median value in a time series array? Currently I copy the array, sort the copy and then select the median. Seems longwinded but couldn't find any standard functions to achieve the same thing. Anything better? Thanks V
Hi I am having a lot of pain with an Error 130. From what I have read everything points to a NormalizeDouble issue but I can't seem to solve it. The ea takes the low of the day and places a buy order, I have written similar code using 'Ask' as a price reference with no problem. The broker is Alpari...
Hi, Almost all is in the title. On a live chart, there are several way to do it, for example with the OnTimer event handler. But what about the Strategy Tester, timer doesn't work, sleep doesn't work, tick count is not reliable. I am looking for a way to open a trade (or run any code), x seconds...
I've got some ObjectCreates that are displaying text but the text is being cut off at approximately 64 chars across the chart. How do I increase the allowed width of an Object?
New date 646 - appears to have a bug with " Default.tpl " file - or Default Template. Prior update - one could - setup a template w/indicators etc - customized chart per personal needs. Say 5 Moving Averages 5/12/53/107/200 - Save the template as 5n12. open new chart - normal default is simple...
Hi all, I have a problem with MetaTrader 4, each time I open it it want install an update, this is a problem for me because I have some script who uses some dll and I must not update it. For each open windows ask me if I want take the permission at MT4 to do some modify, this problem exist because I...
I do not want to update to this 600 build. I am currently sitting on build 509. Would be massively grateful if someone can help???
Hi there, In my EA, i look for some signals based in external indicators i call with "iCustoms". The issue is that i call like 50 times the indicator and although they have some different settings, there is maybe 10 unique iCustoms. So my idea to speed it up would be to first store the 10 iCustoms...
Hello external variable like bool if i selected manually to one of 2 cases and from program inside i want to reset it as if i remove the EA and attach it again on chart external bool Run=true;int start()  { if(!Run)  {  Run=true;  }   return(0);  } That is example if i click on Run on EA and select...
Hi Experts! I would like to get a little help. There is an EA, which only begins to work when there is enough bars available. A newly installed MT4 contains only a few candles, and so EA does not work. Are there some programmatic solution that EA downloads the minimum required number of candles,...
Hi. Can I get the duration for an operation? I can get the duration in minutes when I close a order that show how many minutes this order remained opened. thanks
Hi, I just bought a new computer and have to start from zero. I try to put new indicator on mt4, do all the steps correctly, but when I open the aplication of MT4 those indicators doesn`t appears. I configer it the same way as I used to do but... nothing. I copy them correctly in "experts" -...
Regardless of what time frame I'm running an EA on I want to be able to see indicators with different time frames (2,3,4,10,20,etc). The documentation seems to think I just want to view a value while on attached to non standard time frame. I want to use the value of a different time frame's...
kum01049
Hi, Any coding to read windows registry key and compare it?
Ok, I've been stuck on this problem for just over a week now! It's a very simple bit of code:      C_time=Time[0];       C_time1=(C_time-(240*60)); // time 4hours ago.     BS1=iBarShift(NULL,PERIOD_H4,C_time1,false);   Line1[0]=iMACD(NULL,PERIOD_H4,10,17,6,PRICE_CLOSE,MODE_MAIN,0);...
Hi everyone, I am trading using the attached indicator, when a sell signal is triggered I buy, and vice versa. It works strangely enough. I would like to surn this indicator into an EA, would someone be able to help me adjust the code, instead of printing the signal and setting of an alarm I would...
How is this calculated? I have got this error for 2 Buy-Stop and 3 Sell-Stop-Orders. The Stop-Orders needs: entry, SL, and TP. A valid SL must be 'bigger' than the StopLevel but what is the counter-value for SL - let's say Buy-Stop: I calculate the Entry like e.g. Ask + 6 PIP 1) StopLevel <= Entry -...
How can I change the "speed" of the chart when backtesting in the visual mode....?? When I move the "slider" to 32 it is way too fast....and 31 is like watching paint dry..... too very slow? Does anyone else have this problem??
From the post "http://www.forexfactory.com/showthread.php?t=125117", I was inspired with the idea to use namepipe to communicate with Excel. However, when I run the following script in MT4, I always receive an alert "CreateNamedPipe failed". What did I do wrong?...
I want to be sure I understand how MT4 handles the forex servers. I’ve been working with the assumption that there are market data servers which tick the EA and a broker server which I need to query separately for account information. I started cleaning up an EA to stop it from checking...
Is this possible to use timeframe 3m,10m for EA, which is not available in chart?
Why MT4(build 625) hang-up? === Step === (1) create a new chart (2) drag and drop Expert Advisor ( testEA ) onto the chart (3) repeat key press ( key is 'j' or 'k' ) (4) MT4 hang-up << text code (Expert Advisor) -- testEA.mq4 >> int OnInit() {   return(INIT_SUCCEEDED);}void OnDeinit(const int...
Can someone explain to me what cross arbitrage is in great detail? I also appreciate links/refference. Thankx experts.
934 does not work for me because typing delay. I would like to go back to 933. Is there a way to do it?
If use an indicator (custom or not) in my EA, when is that indicator updated? Is it updated on every tick or only when it is called from the EA?
Ciubo
Hi, my name is Alex and I am trying to develop an expert advisor to profitably trade the news. The first question that I need to ask is: what will happen when ticks are really fast (let's say 5 ticks in one second) . What will the EA do if it can't complete it's execution? I read that it will skip...
Please help - I am getting some strange error in the log - how to fix it? I do not know what the failed list is for. Should I reinstall the metatrader? 2014.05.03 10:11:15.029 Signal: '2089074194': failed get list of signals,connection error 2014.05.03 10:10:53.651 '2089074194': previous successful...
I have been trying to make it work but not getting it right. Probably my logic isn't right at all. The goal is: EA Should open trade only Once when it gets a New Signal. Even though the opened trades got closed, it wont open any New trade unless it gets the Opposite Signal. So for this what I have...
F44T94
  EA with custom indicator (19   1 2)
Can someone help me? I want to use the super trend indicator in my EA. If the trend is down he should open a sell trade and if the trend is up he should open a buy trend. I only need this simple method to understand the logic about that because I never work with an indicator and yes I am a beginner...