Download MetaTrader 5

MQL4 and MetaTrader 4 - page 858

To post a new topic, please log in or register
Hello, I need auto stopp loss and take profit script. I just enter values with metaeditor, open MetaTrader and run script on my chart - I need exactly that script.
#property indicator_chart_window #property indicator_buffers 3 #property indicator_color1 RoyalBlue #property indicator_color2 Red #property indicator_color3 Yellow extern int AAB_Price = 0; extern int AAB_MAPeriod = 40; extern int AAB_MAShift = 0; extern int AAB_MAMethod = 1; extern int...
Hi, is there a possibility to export specified time OHLC data to Excel file? For example, automatically exporting daily 02:00(M1) and 04:00(M1) OHLC data to excel, and at the same time record the highest and lowest price within this period.
Hello. I try save in txt the Close price. int start() { //---- int _time_waiting=0; bool tester=False; int handle; int j; for (j=2; j>1; j++) { FileFlush(handle); FileClose(handle); if (tester==False) _time_waiting = TimeLocal() +...
Hi, How do I post trades from my metatrader to my web hosting server,and from there connect to my clients platform and auto execute the trade? I have seen pipserver dot com, doing the same. The EA given to clients logs in to my web securely and from their opens, modifies, and closes trades. I am...
Is there a way for MQL4 to adjust lot sizes based on the currency pair. For example I use AccoutnBalance to calculate the trade size but this should be adjusted for each pair. If my account is in GBP, then a trade size of 1 on GBPUSD is actually $1.5 and if I want it to be £1 per point then it needs...
Hi all, Recently i can see a lot of buzz around the Artificial intelligence EA's. About how they can learn the pair characteristics, and get better all the time. Anyone can point me to a more detailed resource about that niche? Some articles? Maybe a book? Is it still involve only MQL4/C/C++ or...
hi, i am currently thinking of switching broker, i know that broker discussons are not allowed on this forum, but this is a specific issue with mql language. the broker i am talking about offers its own trading software with the support of EA, but before i switch i would like to demo test my...
  run code once (7)
I would like to run this code once on Sunday at the opening of the broker. However, I have this EA running on 12 different pairs. Any ideas on how to run through the code just once for each pair? I thought about putting in the Hour and Minutes and seconds but it relies on a tick coming through to...
i wrote one indicator and i want it to be sending email to me but it does send it. I do not know if i am going to do anything on the platform for it to be possible if am going to do anything,please help. Also is it possible to be sending it to the mailbox of the platform ? And what is the...
New article How to Order a Trading Robot in MQL5 and MQL4 is published at mql5.com: With the launch of the "Jobs" service, the MQL5.community became an ideal place for placing orders and providing programming services. Thousands of traders and developers visit this resource on a daily basis, and...
What is the best method to code for an event of when the MT4 closes a trade based on a set stoploss. For example, trade A opens, a stoploss is set, trade B opens a stop loss is set, when a stop loss is hit, I want to move the stop loss of the remaining open trades to the price where that stop loss...
Dear Forex People I do not know more about Economics than ordinary people. Chosen USDCHF currency pair for liquidity, an studied the movement for several Years. Especially obivious on 1H timeframe: After a turn in one direction, starting the next hour scharp: The opposite turn, nearly the same pips....
Can someone please tell me what's wrong with this code snippet, which is part of an EA I am trying to develop? The indicator "myIndi8" has eight "extern" parameters and eight buffers, four of which are up arrows (0,2,4 and 6) and the other four are down arrows. The indicator puts an EMPTY_VALUE into...
Hello fellow mql programmers. I'm trying to: 1) Calculate the total risk of all open positions function to be used with EA's I create in the future. 2) Calculate the total number of Un-Hedged Lots I currently have running. 3) Calculate the total number of Un-Hedged Points I currently have running....
Hello Everyone I am having a problem with my ordersend() function, and I hope someone will help me. I have developed my own expert advisor with my own strategy. What actually happened, during the fast price movement my expert advisor does not place an order, but in case of slow movement it...
Is it possible to call the MQL function from the DLL ? like calling AccountNumber() inside the DLL so I have a plan to call and check the AccountNumber() from the DLL file and not from the MQL (ex4 file) can someone guide me on how to do that ? thanks
I need value of the last closed position    for(int b=0;b<OrdersHistoryTotal();b++)     if(OrderSelect(b,SELECT_BY_POS,MODE_HISTORY))      if(OrderSymbol()==Symbol())        {          Comment("b = ",b," OrderTakeProfit ",OrderTakeProfit());        } But it somehow shows zero while 3 closed...
have here a code for a working Swing Tradeing Strategy on EURUSD, on other pairs look like work also, did just testing EURUSD. Offering you this code for all developers, could be usefull for you to learn and develop own systems, i would be lucky if i could get such code years before. for more info...
Tired of lost trade..why not see the actual trading making profit on ur screen..The trading with be soon will be close to avoid disturbance to the brokerage..but if you r interested to know the secret.. send USD100 via paypal to lansera@yahoo.com and the secret will be reveal..money send is not...
Hi, I'm new at MQL4 programming, and I can´t figure out how can I filter every tick from the open price. I want that my indicators and EAs run their routines only at the bar opening price, ignoring all the rest of bar ticks. The problem is that they continue to return me buy/sell signals on every...
  EA Box (4)
I accidentally removed the EA Box from Meta Trader and can't figure out how to get it back
I thought that a tick was an indication of a change in price BUT - I have an EA attached to EURUSDm 5 decimal place chart which does open trades on this pair as well as GBPUSDm without an open chart. if I Print(MarketInfo("EURUSDm",MODE_ASK),5); then I get the same value (eg 1.25567) printed to...
I found a fun read here (article) on predicting EMA crossovers. If I understood it correctly, for EMAs, we can see a recurrence relation between yesterday's EMA and today's EMA, and by shifting this relation forward, we can solve to figure out the approximate price needed for tomorrow to close in...
Been trying this all day but now just getting myself more and more confused. Say that I want my EA to stop trading from 8:00pm until 6:00am the following day, how would I go about this? I have code for finding the relative GMT offsets for the broker, local time, London, NY etc all working correctly...
Hello everyone, i'm using the wininet.lib to reach user data from my server. On the machine where i have developed the c++ dll, it works perfectly. If I try to use the dll on another machine, there is an error "dll can not be found". Can anyone help my? Thx in advance
Hi All how to make fonts in Fibonacci Channel bigger and bold? Thanks, AM
Hi All I have been emailed Trade Protector 1.2 (loaded it to MT4) and it is not working properly/or i havent set the correct settings, I have searched for it but cant find it in the mql site. Does anyone have any info on it? or where it is located? also, i would like to set up EA and would be happy...
Hi, I have some application development background and would like to get started in learning MQL4 and use it to program automated MT4 system. Appreciate your advice if you can point me to a good path to start. Thanks! fchia
We are using an EA we like very much but when the platform crashes which is alot lately (will not name UK based broker) the EA doesn't pick up the old orders, so if there is a floating loss, we may as well realize the loss and reset it. Thus, a crashing platform can cause the EA to actually lose...