MQL4 and MetaTrader 4 - page 70

Hi, Say I run an MT4 optimization from 01.01.2016 to 31.12.2019 and then I want to test all strategies from previous optimization on the period 01.01.2020 to 31.12.2020 to eliminate those with poor results (on the basis that they were probably overfitted or not statistically significant enough so
ask for help For payment please check Order number: 919895545 [...]
I've created this so far, but for some reason the ObjectSet is not working properly. My comments are in [] #property indicator_chart_window #property indicator_buffers 0 #property indicator_plots 0 extern datetime ArrowDate1 = D' 2023.03 . 03 00 : 00 '; extern double ArrowPrice1 = 144.8730 ; extern
Hi every one I wrote an arbitrage expert advisor which is trade two pairs in same time. expert is working good in demo account but when I change account to real, it s working for some time and also open positions but after a while it s freezing. restarting the MT4 don't solve the problem. again when
below here we can see the last buy position should be opened when there are 3 supertrend in green, the problem is we can see on chart that shift 1 of these 3 supertrend doesnt have all 3 green, one of them is red, down 1.06397, up 1.06185 and up 1.06242, but in journal we see up 1.06127, up 1.06242
[Deleted]
Hello, I would like my indicator to save all ohlc values to csv file once loaded and then do not save anything more until manual reload of the indicator. This is what I did: int handle = FileOpen ( "export.csv" , FILE_READ | FILE_WRITE | FILE_CSV ); int OnInit ( void ) { if (handle> 0 ) {
I am growing very tired of going to each currency pair chart and setting the magic number each time I compile my code on the test (not talking about tester) I am running. Is there a code snippet out there where I can count all the currency pair charts open with an EA called "bob" (for example) and...
Hi, I would like to create a dashboard with 28 rows and 14 columns using classes. However, I am having trouble with the 12th and 13th columns as they are not displaying correctly on the chart (please refer to the attached photo). I would greatly appreciate your help in resolving this issue. Thank
Hello everyone, I've been struggling with a stupid problem for a few days now, and I've come to the realization that MetaTrader 4 simply doesn't offer a way to update .hst files so that functions like iClose() can always read the latest candlesticks from the file. Somehow, the iClose function keeps
Dear friends, need your help. If EA already run in one pair, then how to avoid EA run in the other pair? So EA only run in one pair. Thank you.
Hi, i need to extract draw down per trade from an EA. I've had a go at the program (below), but i am not sure how to extract the high and low values between each trade execution. also how would i extract this directly to csv? void OnTick () { int HighestCandle= iHighest ( _Symbol , _Period
Is there a possibility to start a backtest from the command line? Something like "terminal.exe -tester EAxyz EURUSD 5min 2000.01.01 2010.01.01" ? Any other idea, how I could start a backtest from outside? I want to use external programs that start different backtests automaticaly. But I have not...
I tried demo on mt4 and see that on metaquotes-demo, for EUR/USD, there is no commission nor any spread except for roll over hours. Last year on metaquotes-demo, the simple EA I used scored very well
//+------------------------------------------------------------------+ //| testma1250.mq4 | //| Copyright 2021, MetaQuotes Software Corp. | //| https://www.mql5.com |
How can i make the trade utility size bigger on my screen, it is literally 1" x 1.5" and cant see any of the boxes or options
Hello everyone I am need of switching indicators onto the top of the main chart and could not do it. I did over 4 hours of trying to figure how to but was not able to. if anyone can help guide me on how to setup 1 indicator chart on top of the main currency exchange chart, it will help east alot for
Hi   I am getting an error message - IgnoreArray - invalid array access - on this .mqh file, when trying to compile it. Is it possibly related to the changes that came with v600?I can't seem to find enough info on the eror message to help me work out what the problem is. I am hoping to use this code...
I have a script which create hst files, i want to use this chart data from the hst files for some indicators but i see when i use iClose() function that the latest close price is only giving back correctly when i open a offline chart from the hst file and when i update this offline chart, then i see
Hi, I have an expert attach to a chart. It need to iterate through all other opened charts, and iterate through objects in all of this charts. I iterate through charts without problems, but I don't know how to iterate through objects in another chart than the one where the expert is attached
Hi, thank you for taking the time to read this thread. I added a new function to this program so that it only closes its own orders when trading and does not close other orders that were opened manually or opened by other expert advisors. By adding this function, the program makes only one order
hello guys , hope you are doing well. i wrote a code that i'm currently using to calculate profit factor for a specific magic number : double Grosswin(){ int win=OrderProfit(); double grosswin= 0 ; int i= 0 ; if (cnt> 0 ) for ( i ;i<cnt ; i++) if ( OrderSelect (i, SELECT_BY_POS, MODE_HISTORY)) if
Hi, I have been trading for a few years, and finally decided to take the plunge and learn more about building Expert Advisors. Playing around in - Bots Builder - has helped a lot. I used it to construct a very basic EA. The next step is adding a License Check Function - where the EA expires after 30
  Using spline(s)  (23   1 2 3)
This thread will be dedicated to spline(s) usage in technical analysis ________________________ Direct cause for considering splines is the request by simba to create a manual nonlinear trend line, and how ever I thought of it, it seemed that the most logical way of doing it was to use some of the...
The problem is from the Mechmatov forum, here . Петя заметил, что у всех его 25 одноклассников различное число друзей в этом классе. Сколько друзей может быть у Пети? Comment: 1. Petya is also in this class, i.e. there are 26 people in total in the class. 2. If A is friends with B, then B is friends
Hi , i have this code i want to test a brokers stop levels . When i comment out the sections defined on the timer function the timer can be set . When i leave it as is i get an error "Cannot set millisecond timer (100)" It's probably something i missed , but i can't find it. Also , an mt5 is running
I deleted the Metatrader4 file in open data files inside the application inside then uninstalled the application on my macOS big sur. After that i downloaded the ready-made mt4 package from https://www.metatrader4.com/en/trading-platform/help/userguide/install_mac Once installation done, i can't
A custom indicator included as a resource slow down 60 times tester against using the same indicator with the same inputs (not as a resource). Is it a bug? Or am I doing something wrong? Here is a simple EA so you can try it: #define INDI_AS_RESOURCE // If you want to run the EA without a resource
[Deleted]
Hi all, I'm trying to learn more about appdialog boxes. The final thing I wanted to learn was how to remove the MinMax and Close buttons from the top right hand corner. Shown in the image: So far I'm struggling big time with how to exactly remove them. I would input some code, but I don't really
Hi champs, This is probably a newbies question and please accept my appologies if it is, but I've been searching for a couple of days now and couldn't find any working code to close all my open orders at a certain time of the day. Below is an extract of my EA in MT4 and I've tried several pieces of
Hi there:-) I'm new to coding in MT4 and would love if someone would be so kind to guide me in the right direction:-) I have attached an indicator that works brilliant... It automatically saves a screenshot when you open and close a trade... My problem is that i would like to set a custom folder