Expert Advisors and Automated Trading - page 80

Hi! I want to send an OANDA order request via mt5.send_order(), but it is returning none type. Here is my order request: action: 1, Type: int symbol: US100, Type: str volume: 0.01, Type: float type: 0, Type: int sl: 16627.5, Type: float tp: 16701.75, Type: float deviation: 20, Type: int magic
HI I am trying to use iCustom with the simple call form of OnCalculate indicator. int OnCalculate ( const int rates_total, // price[] array size const int prev_calculated, // number of handled bars at the previous call const int begin, // index number
Hello. I have been reading dozens of articles for three days, but reading those articles just gave me a headache. I just want to do something simple. Create a simple field on the chart where the user enters a value as a string and then I can enter that value into the variable. Please, without
Dear developers, i am trying to write a hedging expert advisor and i have some strange issues with making it work properly, first let me explain the whole idea and then mention the issue: suppose LotMax = 1.0 (input box variable) it is p etty much a bot that when it hits its TP it applies some of
hello, is there a script that gives alert when the account balance reaches a certain level, thanks in advance
Is there a way to display in a bar chart ROI and DD by month and by year on startegy tester report or on a histogram inside the tester? I have tested my EA since 2008 to 2023 and i want to visualize these stats
Is it possible to convert two not very complex advisors from MT 4 to trading in the MT 5 terminal? Auto-translation applied by moderator
I have this code for saving tickets that are stored in an object of the CArrayLong class void Save( void ) { if (m_tester || m_optimization) return ; //--- string name = "" ; if (!GenerateFileName(name)) return ; if (m_basket.Total() == 0 ) { if ( FileIsExist (name))
hi guys i bought an EA which is not working on my VPS PC now. I am loggin into my mt5 account and also into the community account, but the EA does not appear. when i check the market and click on the EA, it just says renew...but i rent it last week for the duration of one month. how to solve this
i have two charts on the screen. both representing the same currency but different timeframes 15M and H1. below code i use to draw an arrow. works fine but problem it is getting drawn on M15 timeframe. i want to draw it on H1 timeframe. I believe the issue something to do with the chartId but
Good day. I would like to find out if there is a way to drag and move (or another way) ALL stop losses at once. For example if you have multiple trades open and want to move all the stop losses. Currently I drag all the stop losses to the new target, but would prefer a way to select all and move
Is the description for my freelance job here at MQL5 understandable? And what financial outlay should I plan for? Thank you for your feedback
Hi, I have a strategy and I optimize it for a better input parameter. Now I optimize + backtest + forward test, supposedly the result of OptimizeA parameter was the best in backtest but on forward test OptimizeB parameter was the best. While backtest shows best parameter on the historical price and
When analysing the GBPUSD chart with 1h bars, I noticed that the tick volume shown for each bar is higher than the tick volume you get through MQL. I expect those 3 to be the same: A) Tick volume for a 1h bar in the chart B) #ticks after we call CopyTicksRange with COPY_TICKS_ALL and `from_msc` and
Hi everyone, In the same I want to : - Buy Limit( BuyLimit ) - Buy Market ( Buy ) - Sell Limit ( BuyLimit ) - Sell Market ( SellLimit ) Would you recommend creating 4 instantiations of the CTrade class? To better manage the different methods and avoid confusion? What do you recommend? Best
[Deleted]
Hello Members I have created Custom Indicator for %b (BB,MFI &RSI) values which is working perfectly fine. Attached jpeg for the indicator chart. I have also create a CLASS to access this custom indicator values and when try to run it in Test EA, get "cannot load indicator 'Relative Strength Index'
  file  (7)
Hello geniuses I have a code that hedges a some of orders and stores them in a file. If the robot is removed from the chart, after restarting, the robot can read the hedges from the file, but if for any reason the Meta-trader program is closed, after restarting the robot, it will display all of
  MQL5  (4)
Why I can't get total order history data with code HistoryOrdersTotal() and HistoryDealsTotal() in mql5
Hello i have 4 EAs,Testing in strategy tester in MT5,When i test EA with my broker data it is not same with tick data not same result,But when i run EAs in live account and when EAs will open positions,And after sometimes for example after 4 months,When i run strategy tester for same period 4 months
Well I am not a coder but i got some one here who coded me an EA which was working perfectly so far on demo. now when i used the same EA with same setting on another broker cent account my EA is not taking the trades as it was suppose to take. I have applied two EA on my account, one is to trades
Hello, I need to get the high and low price of RECTANGLE in my EA with below code. double price1 = ObjectGetDouble (chart[idx].ID,obj_name, OBJPROP_PRICE , 0 ); double price2 = ObjectGetDouble (chart[idx].ID,obj_name, OBJPROP_PRICE , 1 ); but I receive wrong prices as below
Hi, My custom performance metric returns 0 value on journal tab but on backtester tab it returns inf, I'd like to ask in what scenario that the OnTester result in inf
I am a new learner of MQL5 and I want to do the following but I am not sure it is possible in MQL5: 1. Get the price of a sticker every time it has a new price (more or less get the "real time" price" or prices of the last two or three update). 2. Write an EA that runs/loops every time the price of
switch (x) { case 1 to 4 : g= 1 ; break ; case 5 to 7 : g= 2 ; break; . . . } not working even case 1 - 4
Hi! I jad a running signal subscription on MQL5 before, but the new one didnt copy the first trade? Is there some kind of error log to understand why? Can it be because he traded „XAUUSD“ and the symbol with my broker is called „XAUSUSD+“? On the other hand the trades of the first signal traded as
  MQL VPS  (12   1 2)
So today I just connected my account with MQL VPS through MT4, it deactivate the Auto Trading and traffered the ea to the VPS. The VPS is currently running one Ea but I have another Ea which i want to run in the same account but that ea requires DLL which is not allowed in MQL VPS. Will it be a
i use this code for calculating volume based on riskAmount and stop loss distance. this code works fine with forex trading but with gold it is not working properly. with gold the volume is always wrong it always give me 10 times the actual volume i need. double calculateVolumne ( double riskMoney
Hello, I have a question regarding the principle of drawing and profit per day, I would like if for example we reach 4% gain or if we reach 4% loss the EA does not open any trades until the next day how to do it thank you
I am trying to delete pending orders when I open a position on my chart. The problem is that if another strategy (same EA, different magic) on same symbol has an open order, the pending order will be deleted instantly. I am probably missing something, but cant find what. What I can understand, it is
Hi everyone, is there a function or simple already made code that would result in number of minutes instrument is traded in a day? Par example, UKOil is traded from 3:05 to 23:50 and forex pairs from 0:05 to 23:55. Regards