Download MetaTrader 5

MQL4 and MetaTrader 4 - page 7

To post a new topic, please log in or register
Thanks for you help. I was wondering when I placed my EA on my chart and turned off my computer. Is the EA going to run?
Hi, everything is OK about my EA. However whenever i put this protection code to my ea. It stopped using TP & SL!! I have tried to use account verification code... please take a look below //+------------------------------------------------------------------+//| Waelmore I//|//|    Created by Black...
I wanted to start a mt4 at the location: C:\Users\cas\Documents\MT4\mt5. But as  you can see the starting process hangs using one of my 4 kernels completely (CPU = 25%) and , forcing the other running mt4 (1-4) to have a higher cpu-usage as well and , the system requests all of a sudden 16% If...
In my mind I have the for loop and the array set correctly what is causing this array out of range error? Keep in mind I am brand new to programming and this is my first attempt at a functioning program....
Hi, Is this possible to display the comment on chart with bold/big size font and different colour? currently i used to display comments as normal. but i like to display header as bigger font with bold and ey-catch colour. Please help me if there is any functions available to use? currently i use:...
Hi Guys, i've been searching with not much luck for an MT4 version of the ConnorsRSI. A lot has been said about this indicator, which was developed by Larry Connors and Cesar Alvarez. The indicator is available for amibroker and tradestation but find no coding for MT4.. Can someone be able to help...
Need help on my 2 MA crossover EA. The EA will close the trade if the price reverse too quickly (but did not hit the stop-loss). I think is because the MA also reverse/repaint. I think is because the MA is "drawn" on every tick. How can I make it 'trigger" only after the close of the candle? Hope...
Hello MQL4/5 Community, I have a question regarding a function i want to build into my custom indicator "my indicator". So basically my indicator cointains multiple indicators and summarizes them into the buffer sum[i]...
Hello, i want to build a simple indicator about my profit-loss analysis... as Select by pos is related to Ticket ID/Order Date... is it possible to create the same one but sort by Closing Date
I've got this function which i don't know why it doesn't  work. I want the EA to place a buy order is last closed  sell trade was a loss. double LastS(){double ProS = 0;       for(int i=OrdersHistoryTotal()-1; i>=0; i--)         {         if(OrderSelect(i, SELECT_BY_POS, MODE_HISTORY) ==...
Only the purchase position opens Can you help? thank you all void OnTick() { if (Bid > High[1]) { OrderSend(Symbol(),OP_BUY,1,Ask,0,Bid+40,0); ; } if (Bid < Low[1]) { OrderSend(Symbol(),OP_SELL,1,Bid,0,Ask+40,0); ; }}
Hello, Wondering if someone might have the code needed to add a Fib Retracement on the High/low of the Previous Period on the chart?  Example,  If I'm looking at the hourly,  it would place the Fib on the High/Low of the previous day (Which is between the period separator), If I'm looking at the H4...
Hi All,     Have tried searching with no success.  I am having trouble sharing doubles between 4 EA's running on 4 separate Metatrader4 accounts running on my VPN.  The VPN is running Windows Server 2012R2.  I have used GlobalVariables years ago with no problems... but now they don't seem to cross...
double L24[]; double L32[]; double L40[]; double L48[]; i try to get those values,but i couldn't code. please help me .how can i get buffer value when arrived every tick? <Decompiled code removed by moderator>
<Link Removed> What are you thinking about this service.
Hi all, first of all, English is not my native language so I hope you won't get angry, if some misunderstandings occur in this thread ;-). Furthermore I want to give you a realistic view about my programming capabilities - well there are almost none. I can print "Hello world" in Python and know...
I have an Indicator that displays some information panes on the Chart window and one of them is at the right top side of the chart. The problem is that when someone will attach an expert to this Chart, the Expert name and its smiley are appearing right there. So, I need one of this two options: 1....
Dear friends,    I am learning to code in mt4 and got a hang of it. I came across an indicator that display buy and sell value as seen in the screenshot below. Please guide me with study material or sample code on how to display buy and sell suggestions like seen in the screenshot. The logic is my...
  Need help with coding (130   1 2 3 4 5 ... 12 13)
Hi i am trying to code a very simple EA but i'm not a programmer and i've never made an EA before. I took the MACD Sample from MT4 and edited some parts and deleted all the rest that i thought i don't need. I'm sure my code is really horrible I would like the EA to work like this: My custom...
Hello! I'm working on several projects and for some of those I require to be restricted without having to buy/rent a server to make kind of a every 6 hours check for license numbers or something like that. I came up with a fairly simple idea, and I just wanted to get opinions on that and other...
Has anyone experienced (in Metatrader 4)   having their position closed for no reason? in the DEMO version? It happens after about 30 minutes.
What and why do I get this as my MT4 EA opens an account?
hi all, I hope you are doing well. I'm looking for a MT4 programmer to develop the following EA: Step1: Write every hour all retrievable details from the orderhistory section in a mysql db table.(drop the old table in mysql db) Step2: Write every hour all retrievable details from the open/pending...
Hello all! I'd like to add to some EA's a notification function that, well, notifies when a TP or SL has been hit. I made a kind of BETA version of the actual code but I'm facing some troubles that I'm not sure how to overcome:    for (int i = 0;i < OrdersHistoryTotal(); i++)    {      bool...
  Get Computer Name in mql4 (22   1 2 3)
Hi, I want to get computer name in mql4 in order to make original log file including computer name which MetaTrader runs. I think it is possible using GetComputerName function in kernel32.dll, but I don't know how to implement it in mql4. I found a kernel32 api example and modified it, but it...
Dear Metatraders  I am trying to develop an indicator that show me the highest high and the lowest low of the last 100 bars of all Major currency pairs,  This is part of my codes: double dEURUSD[2];dEURUSD[0] = High[iHighest("EURUSD",PERIOD_CURRENT,MODE_HIGH,100,1)];dEURUSD[1] = Low [iLowest...
I can only enter integer into the Deviations box. If possible please draw an arrow on the chart please, Red for put and Green for call. thanks Here is the indicator: bollitoucher.mq4
Hello, I'm working on some EA's that uses Trailing Stop Loss, I came around with this code: void Trailing_SL(){    for (int i = 0; i < OrdersTotal(); i++) //Iterar con todas las ordenes    {      bool res = OrderSelect(i,SELECT_BY_POS,MODE_TRADES); //Seleccionar por index i        int Local_ticket =...
I set EventSetTimer(1) in OnInit (bool result is "true") , and I put my code in void OnTimer, but the indicator is still going through OnCalculate, which defeats the purpose of using OnTimer because the data received from the broker isn't faster than 1 second in some cases. Is there a way around...