Download MetaTrader 5

MQL4 and MetaTrader 4 - page 453

To post a new topic, please log in or register
When drew trend line by --> ObjectCreate("Trendline",OBJ_TREND,0,Time1,Price1,Time2,Price2) . What function use to get degree ? thank you
How to set the color of a moving average in an EA,since i cant find any parameter to set it double iMA( string symbol, int timeframe, int period, int ma_shift, int ma_method, int applied_price, int shift) Any suggestions? TY
I have M1 for USD EUR loaded in a single MT4 offline test installation : My Code code at Start = double Hilfsvariable2= (Close[0]); Print("Aktueller Close ",+ Hilfsvariable2); I expected the get one close for each 1 minute candle in the mt4 journal: These are the lines in the history center:...
[Terminal Panel] at the bottom of MT4, which can appear by "Cntl + T." TODO_01 : assign the different value set for different currency pair in the row of the terminal TODO_02: change the font size bigger perhaps the height of row of the table, too, accordingly. Which file in the source code...
Hello! good afternoon. i want to modify attached source to suit what i want style. this is trend line alert and if price line cross then alert fire but it every bar alert fire so i want to try to make it only one times for alert but no luck. i was used static datetime Time0; if(Time0 ==...
Hi HoW easy is it to program a Good For The Day where; the EA will look at order history just for the day and see if it has gotten like 10 pips? thx
I'm using an indicator called 10.2 TMA slope, and although it compiles without errors, and even works in an EA, when I backtest my EA, a whole bunch of error messages pop up in the journal saying, \ 10_2 TMA slope v1_4B 4_30 for EA EURUSD,H4: unknown subwindow number -1 for ObjectCreate function....
I want to substract the minute value as 10: eg: if i give 00 means it should consider 50, 50 means 40,etc... tried following code. but it seems wrong. can you suggest exact idea to substract the minute? extern int newsDateMinute = 30;newsDateMinute -= 10;
Dear All, I tried to write a 2 ma crossover ea. It seems I don't get into making trades for some reason - can anyone help by looking at my code which is very short and explain what the problem could be please?...
Hello! I opened a sell order a wee more than one minute before the market closes. It shows 21:58 in my case. My order was closed a few seconds after at 21:59 with 2.85 loss as you can see. The balance was 9.89 dollars. So my question is that what "so: 91.1%/6.8/7.5 means in the comment tab and?...
Hi Everyone, I have a custom indicator, attached and I write a script to export data of this indicator. This script works with other custom indicator and for some reasons, it doesn't work this time. I very appreciate your help if you could look to see what is the problem with my code. Thank you and...
Hello, I am working to make an indicator which draws two lines making a range from a 22:00 to 06:00 everyday & continue till value changes next day at 06:00. I have used the iHigh & iHighest functions but I still need to give the Shift Count of the bar with highest high & lowest low in...
Does this differ amongst different signals because the is the second signal that has done that. I thought it just copies trades as they happen on the provider's terminal?
I want a native version MT4 for MAC OS, not virtualized !!!!!
I'm testing my EA at the moment and looking at disaster recovery. I have noticed quite frequently, the terminal loses connection and doesn't always automatically re connect. It takes me to press the rescan server button to re establish connection. This can be some hours later if I'm away from my PC....
//+------------------------------------------------------------------+//|                                                 ForexSession.mq4 |//|                   2011-1-18 16:30:18 oldz.cn@qq.com         OldZ |//|                                        http://www.metaquotes.net...
Hi, I am testing my strategy and I have good results in my test, but when I test my code in real, I have problem that I can't solve. I would like to share my code and ideas with you, and I would like to know if you will help me to solve the little problem and to improve the strategy, because I think...
  time of event (3)
hello, I would like to find out the time of the execution of an event i.e if it is an arrow drawn by the indicator or the time an order executed. how can this be done? thank you in advance
hey guys I'm looking for an EA or someone that can program me an EA I have something very simple in mind and would have programmed it myself but just can't wrap my head around the language. please assist with this I might be willing to pay for this: Email me on jitzu1@live.com if anyone might be...
From searching the forum, it seems that: a) the start() function of an EA runs in a new thread created by an incoming tick. If its still running when a new tick arrives, the new tick gets 'missed' by the EA b) custom indicators run in the main GUI/interface thread, unless called from an EA....
I am trying to delete several buylimits orders when the Stochastics are in the overbought area but the code seems not to work. Where is the problem?//------------------------------------------------------------------+void CheckForDeleteBL()  {   double DValue;   int Total,cmd;   bool result;...
Starting to get a bit more in depth with MQL4 and need some help. Lets say (for example) the price hits 1.5000 3 times in one day. I would like to buy it on the third time. Is there any way MT4 can record how many times an event has happened? I guess my problem is that i want to open an order after...
I see this a lot when people post their code. if(a==b){Dothis;Dothis;etc;} Now, this is not a problem when reading short pieces of other people's code. But when their is a lot of code, it can make it almost impossible to follow. I would think that many would have difficulties finding errors in...
Hi I've recently opted for a rebate in my trading. I get a rebate of $0.90 per lot traded for my ECN account. I want to incorporate the rebate in my code for back testing purposes. The rebate is deposited in my Trading account on the 10th of each month so when I do my back testing I'm going to add...
Hi, I need to know the price of the penultimate order active. The code below is the code to know the price or the last order active, but I need to know the price of the previous order. How can I know it? double retorno_precio_apertura_ult(int NMagb,int NMags){int num3=0;int ot3=0;double...
Is it possible to set up the platform to automatically add a 10 pip stop and a 10 pip limit order when you enter the market with the 1-click option? Shawn
I have written a small EA that must close some manual transactions when the NLMA indicator changes. But it does not want to close the transactions when it should and I cannot find out why! Is it perhaps my empty deinit? Can you possibly help me solve what is wrong that I am totally blind for? I...
Is there someway to try force broker feed to refresh. What actions can be taken? Delete data restart and run a script? ########################################## Wondering what best action to take is. 1 min data stopped charting for one pair, but ticks are current. 5 min and 15 min still...
Hello all, I am considering linking a trading system currently written in C# to trade an account from the MT4 platform. The system is essentially finished as a standalone executable file set. In order to accomplish this quickly and with a minimum amount of redesign, I am considering writing a DLL...