Expert Advisors and Automated Trading - page 42

I have been working on an EA for some time now and suddenly the code just seems to not work on my VPS anymore but still works just fine on my home PC. The issue seems to be that the trades open just fine but then modifying the stoploss of an open trade throws errors. I have tried copying the code
Could you guys please help me find out what's wrong with this MQL5 EA. So basically the original of this EA is an EA that helps you move SL to the A1 point after the price moves to an A2 price point. I did some modifies this EA to move the SL one more time, SL at the A1 point will move to the B1
Greets, Here's a quick implementation of a grid trading idea showcased here I'm not sure if I've made a mistake, or if the concept simply doesn't work, but it always results in a loss in backtesting. Maybe someone can have a look, play with it, and possibly give ideas. Since the strategy apparently
I am having the following error while i am trying to login to my account using Metatrader5 Python Module: Failed to connect to account #1234567; error code: (-7, 'Unsupported authorization mode, OTP or certificate password needed') Any help will be appreciated
Hi everyone Just as there's a function for selecting a position by ticket " PositionSelectByTicket ", there's also a solution for deselecting a position, although I don't think this will be of much use, since according to the documentation, even when a position doesn't exist, you can still retrieve
Hi there, Im looking to automate the login process and server setup process but i cant figure out hwo to download the server data via python.. It seems that when i manually login into mt5 it downloads a server file first, and this is what im missing i guess... any tipps
So I have a certain trading logic that when met I want to enter the trade at the price of the previous close. This of course cannot be done using a market order due to spread between ask and bid. However, as the candle closes and the next one opens, placing a limit order automatically where the last
Hello, I have always wondered why the backtest results of an EA differ from its live market results. Throughout my trading experience, I have tested thousands of EAs in both backtest and live market conditions. While most EAs yield impressive results in backtests, they often result in losses when
Sir , I want to practice this Example EA MT5. 1) It is working to grid Trading into One Symbol. int Pip_Step( string symbol_2, int magic_2, double StopLoss_3, double TakeProfit_3) { double Open_Price = 0 ; bool LastIsBuy = false ; int TotalBuy = 0 ; int TotalSell
I have a multi symbol EA that I want to optimize using a high spec PC. Does it use market watch to determine which symbols to include or the setting in the EA where I can list the symbols separated by a comma
I have built an EA with EMA crossing logic. It works very well in backtesting, generating BUY and SELL positions when the fast and slow EMA lines are crossing. However, the profit is sadly lost when unexpectedly the trend reverses against the EMA indication, which is something I have been unable to
Does anybody know of a simple EA that will allow me to set simple buy and sell limit orders with SL and TP? thats it! thats all I want please help thx
I don't see the optimization graph tab in the MT5 desktop version on Windows. Has anyone else seen this and how did you resolve? TIA
Was trying to find out more information on backtesting approaches and some additional information on how to handle a condition where the same code is getting different backtesting results on two different machines. We've checked the backtesting settings etc but was looking for more insights into
Hi everyone, I am ripping my hair out trying to figure out why my EA is not turning from the blue hat to green, to show that it's working. I have tried using the VPS from MQL5, restarted, and it still doesn't work. I have tried without the VPS, I have tried all of the settings in the EA options
Hi guys, I swear I'm trying to train my coding and trying a simple hilo EA that with each new bar close signal above or below the indicator it checks how many signals (be above or below) there were in the last X previous bars (only bars independing the time) and if this number of signals/toggle is
Good morning Happy holidays to everyone. I wonder. I like codes that have error handling to easily track any issues, to track whether step-by-step validations are valid. Example if ( ! SetIndexBuffer ( g_indexiMA, g_BufferMA, INDICATOR_DATA )) { if ( g_Debug) PrintFormat ("Error %d: Failed to
I AM GETTING AN ERROR DURING APPLY EA ON CHART "cannot load C/.....Roaming/MetaQuotes/Terminal/..../MQL4/Experts/HFT_EA.ex4
Hi guys, I installed MetaTrader 5 in Python version 3.9 but not find a version, I install on Mac Silicon. Please help me
Hello, My EA tried to open a market position, and when sending the order it got stuck and returned request timeout after about 3 minutes. See log below After that a position appeared in the trade tab with the comment request adding, but that position did not exist. The problem is that my EA
Hi, i have a problem with my code, it executes the order without any problem but when i try to use both orders_get() and orders_get (Symbol = "EURUSD") it returns an empty object. Here is the code and the example (I can assure that there is an open position). CODE: #sendOrder(mt5.TRADE_ACTION_DEAL
I have MetaTrader5 running on Wine on Arch Linux and can connect to it just fine from that machine using the following python script: from mt5linux import MetaTrader5 mt5 = MetaTrader5('localhost', 18812) However, I want to be able to run my script on a Windows 10 machine on the same network but
Hi everyone. I have a problem when I am trying to upload a new expert advisor on the automatic validation page. I read something like 10 threads where it is written that I should fix my code. I am okay with that and is like 2 hours that I am fixing this code again. At the beginning the validator
Hi, I have a script that loads an exe file, and I would like it to also load a EA. How can I do this
Hi When adding this to the expert: #import "shell32.dll" int ShellExecuteW( int hwnd, const string Operation, const string File, const string Parameters, const string Directory, int ShowCmd); #import The expert becomes a script. Is there someway arround this? I need an expert with that import
I opened a Demo account in the broker called <name of the broker was deleted by moderator> and when I tired to realize some backtests was not possible but later I discovered that I need to set USDT, no USD. Until this point OK, but when I did it appeared a new drop-list showing values from 0 to 8
Im confused by the parameters of the CTrade OrderOpen method. I'm not sure how to to skip the "limit_price" parameter and send a simple pending order (not the buy_stop_limit kind for example) this is the way I'm sending a buy stop order and Im not sure If I'm doing it the right way. please do not
Hi guys, I need a help regarding the lot multiplier. I've made a multiplier that follow step balance - so it increases first lot accordingly to the balance of the account. However I have a problem setting up the multiplier. So far I've found the ROUND UP option but it's not good, for example when
if (G1[GridArrayLevel].Grid_Buy_Pos== 0 && CurrentLevel!=CurrentLevelCopy) //open buy order { ZeroMemory (request); ZeroMemory (result); request.magic = g_4magic; request.action = TRADE_ACTION_DEAL ; request.type = ORDER_TYPE_BUY ;
Anyone aware of a MT5 utility program that allows one to set a trailing stop loss based on volatility? ie. TSL = 1.5 ATR