The following is the code: if(distance<MarketInfo(Symbol(),MODE_STOPLEVEL)+5)distance=MarketInfo(Symbol(),MODE_STOPLEVEL)+5;if(CheckMoneyForTrade(Symbol(),startposition,OP_BUY)==true&&IsNewOrderAllowed()==true) { if(open=!OrderSend(Symbol(),OP_BUYSTOP,NormalizeDouble(startposition,2)...
I want to make each day open, the ad is loops (Hedging style) The values used to open orders on a daily basis are not equal, they are the values of the day. Some days to order to go to another day. For example: Makes the next order opening time in the first day's loops take the value of...
Hello! In an EA, I modify the SL and then I want to return the new stop loss as the following: current_SL = OrderStopLoss(); But I got the original SL (before modification) into the current_SL How can return the new OrderStopLoss() into the current_SL Thanks. PS: I defined the current_SL as double...
Hello, I am pretty new to mt4 and have limited understanding of what is possible code-wise, so if I ask about some impossible stuffs then simply say "no can do.". 1/ Would it be possible to color tabs in mt4 based on a simple yes/no condition ? ( the tabs I mean currency listing letters that are...
Hi LTF was 60m and then it changed to rubbish value: https://i.imgur.com/bqt4Vjj.png Also when I copy all to excel, some values are corrupted: How to fix it? https://i.imgur.com/1Q9vcBQ.png
void OnTick() { datetime candletime=0; datetime currenttime=0; currenttime=Time[0]; double K_line=iStochastic(NULL,0,20,3,5,2,0,MODE_MAIN,1); double D_line=iStochastic(NULL,0,20,3,5,2,0,MODE_SIGNAL,1); double pK_line=iStochastic(NULL,0,20,3,5,2,0,MODE_MAIN,2); double...
<I would like to test from the Candle which is assigned randomly.> 1. However when I open the HISTORY from the TOOL of FX, it shows like below, ASKING : ***IS THERE ANY METHOD TO SEE THIS LETTER TO BE CORRECT LETTERS? (ANSI and UTF-8 is same result. Do I need to download any letters?) 2. If you tell...
Hello, I place an Order, but I get the Wrong Order open time. Can someone tell me, where the error is? My code: if( OrderSend(Symbol(),OP_SELL,0.1,Bid,3,0,(Bid-0.0003),NULL,0,0,Red)) { Print("SELL order opened : ",OrderOpenTime()); delTimeOpen( cnt...
Hello, according to the documentation (https://docs.mql4.com/constants/io_constants/messbconstants) "The main flags of the MessageBox() function define contents and behavior of the dialog window. This value can be a combination of the following flag groups:" But when I try this: int PlaceTrade =...
Hi folks, how are you? I have a question, can I import external charts to analyze in mt4 platform
I do not know how the candling system in MT4 works. I am under the assumption that they are "japanese" candle sticks. They Have Open, High, Low, Close But They Are discontinuous. Like This: Even on something like a 5M graph... Why Is This? This Makes Absolutely No Sense To Me. I am Assuming That a...
Hello, All the sudden my windows computer doesn't know how open MetaTrader. When I click a link in the market, I get a box asking me to select how to open mql4buy. Does anyone know how to set the correct association, so that it will work again? Thanks in advance. All the best, Fred Langemark
Help me I'm writing code. Create a button to close all orders and Close only Profit order Button close all button is working but close only profit not working. void OnChartEvent(const int id, const long &lparam, const double &dparam, const...
[Deleted]
I create an Appdialog from #include <Controls/Dialog.mqh> and I need to use Run function to run my app dialog on Strategy Tester mode. How can I do that? Where should I put myAppDialog.Run(); to run my appdialog on Tester mode?
Hi all, Newbie in forex. What does the volume indicator in MT4 mean? I saw something like 4, 20, 100 etc. Does it mean a full 100,000 units contract? For instance, 4 volume EUR/USD means 400,000 units of EUR? Thanks in advance. Hydrom
I'm very new to scripting in Mql4, but I want to make a script that takes the alert message from my indicator and sets multiple orders with the same stop and different take-profits But I keep getting a 129 error and I can't figure out why. Here is the string from my indicator GBPUSD BUY: 4.32 @
Hi, MT4- How can I have my Indicator analyze "X" # of candles before starting? If I dont do that, it may take many days/week before my EA has enough data to start dealing. Thanks
I have somehow managed to shrink the toolbar to just the left side of the page... how do I correct this so that the toolbar fills all the way across the terminal landscape wise?
Hi, Can any one please advise on my coding where I am wrong, basically I want to check 10 next candles after 2 moving averages cross but I am not able to run the counter loop. Please find attached my coding. Many thanks. Aryan
Hi I wrote this code after reading online, not sure how to do the "JPY" part of the code, please help and correct me if there is something wrong with it. Thanks // PIP value for standard lot 100,000 unitsdouble getPipValue(){ string symbol = Symbol(); int usd = StringFind(symbol, "USD"); int jpy...
HI all of you In about last two weeks i´ve discovered the power of MetaEditor . Ive heared about tons of expert advicors and mostly all of them are profitable ( ! hope so :P ! ). During these two weeks ive been trying to code my own expert advisor but i´ve realized that im not able to understand and
Can someone teach me how to solve it to me please?? it is "simple" I created this code so you guys can test it. I just want to know why my OnChartEvent() stops working when i drag the "Box". if you guys check the buttons, you can notice that they stop doing their OnChartEvent() function. int...
Hi, does someone know how to import tick data in MT4 to make a 99.9% backtest without using a commercial software? I tried with Tickstory free but it doesn't work with build above 545...I struggled all day to find a solution but without success, so I decided to open a topic, this could also help...
Hi...i am new in the system... do anyone knows about KPL swing (breakout trading system)...can anyone convert this afl into mt4... //---- heikin ashi HaClose = (O+H+L+C)/4; HaOpen = AMA( Ref( HaClose, -1 ), .40); HaHigh = Max( H, Max( HaClose, HaOpen ) ); HaLow = Min( L, Min( HaClose, HaOpen ) );...
[Deleted]
Hello guys. I need help in coding my EA, so it can avoid news. I tried ti do it myself and what happens, is that the EA opens trades (inside news time), and closes them immediately. Here is the code: Externs: extern bool AvoidNews=true;extern int MinimumImpact=1;extern int...
Hy guys... There is a way to initialize an external datetime variable with the current time ? I'm try something like this: extern datetime fundamental = TimeCurrent(); But returns me the following error: 'TimeCurrent' - constant expected I need to show the current time, not 1790.01.01 00:00
[Deleted]
I have a back testing program that only accepts indicators as DLL's. Does anyone know if it's possible to convert an MQ4 indicator to a DLL? If so, could you please tell me what I need to do in order to convert it? Thanks
Hi, I am building a mql4 code where I'm trying to open EA property dialogue of a particular chart and click allowlivetrading button in a common tab. Could someone show me a specific code to do this ? I'm a pretty much newbie mql4 builder ! (Also not very familiar with Win32API either.)
Hi, I would like to have a line appear on my chart that would match a variable value so I could follow the EA visually. (MT4 please) similar to a Trailing Stop mouvement. I would also like to change the color of some lines in comments if possible. Any help or advice would be appreciated. Thanks.
Hi, guys I need to learn what is the code for set up the stop loss as MA or for example fractals or highest or lowerst, one or them less atr example is correct this code? double MASTOP= iMA(NULL,PERIOD_M5,34,0,MODE_EMA,PRICE_CLOSE,0); double STOP=MASTOP; THEN IN THE ORDER SEND: OrderSend(Symbol()...

You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
If you do not have an account, please register
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.