Expert Advisors and Automated Trading - page 56

int num_cycles = 4 ; int index_cycles = 0 ; double close_price = 0.0 ; // these are just some simple calculations to make it clear double sl_price = 0.0 ; // that after fulfilling the condition for expert removal double tp_price = 0.0 ; // the
  MQL-Obfuscator  (7)
I created an obfuscator for MQL (encryption of source code) for my own purposes and would like to know, if there is any kind of a general/common interest. The obfuscator works so far without problems, but surely has some restrictions which would become visible with other code than mine. I could
hello can someone assist me in telling me how to do a running(cummulative) sum that refreshes after a certain time period ,,,, for example a daily running sum or monthly running sum
Hello, I want to ask the experienced traders and MT5 users, about how accurate is the strategy tester based on real ticks in MT5 in comparance with live trading? Best Regards, Dmitry
long positionType( string symbol = _Symbol ); Error: '_Symbol' - constant expected. Can someone explain why I can't assigning it as a default value
Hello, I had a theory on a winning strategy so I went ahead and created an EA to implement it. This is my first time doing backtesting or using the Strategy Tester. Was hoping to get some feedback if these numbers are considered good and what could use improvement to be viable. Here is the
It means i have a ea and in that EA Trailing stop is mandatory for profitability but my brokers Spread are not allowing the trail to workout! I want to add Live Spread into Trailing stop how can i do that
in this simple snippet I get the following compilation error: 'ticket' - undeclared identifier An idea how to resolve? Improperly formatted code removed by moderator
Hi, I'm currently learning about class for the first time. I have 2 strategy that using the same include variable file, one for long position and the other for short position. In variable file, some of the variable contains trade direction such as SymbolsLong and SymbolsShort and it is used only for
Hi I want to use an EA on several charts (1 is master mode for writing to the file, others are slave mode for reading from the file) int OnInit () { if (InpMaster) Handle = FileOpen (InpFileName + ".csv" , FILE_WRITE | FILE_SHARE_READ | FILE_CSV | FILE_COMMON , "," ); else Handle =
Hello, I am curious about the limit for requests to the latest info available on an economic event. When I went to the mql5 website and tried to scrape the data, my ip got banned shortly after and therefor made me concerned if the same thing could happen if i was to write an EA with a loop, and
[Deleted]
How I can use EA robot in Mobile Phone
Hi, MqlTradeRequest request; MqlTradeResult result; ZeroMemory (request); ZeroMemory (result); request.action = TRADE_ACTION_DEAL ; request.type = ORDER_TYPE_BUY ; request.symbol = _Symbol ; request.volume = NormalizeDouble (buy_volume, _Digits ); double price = SymbolInfoDouble (
Is this Correct Trailing Start & Step Source code ? #include <Trade/Trade.mqh> CTrade trade; void Trail(){ int PT = PositionsTotal (); for ( int i=PT; i>= 0 ; i--){ ulong tick = PositionGetTicket (i); if ( PositionSelectByTicket (tick)){ if (
Hello! I am wondering where I can get information about how the computational process during the strategy optimization works in Metatrader 5. How can I get the best computational results during that process. There is any limit of memory RAM per Core that Metatrader 5 has during the Strategy
Hi everyone, just started working with MQL5 Python integration and found a question that I just can't get right import MetaTrader5 as mt5 time_now = datetime.now(pytz.timezone( "UTC" )) today_start = time_now.replace(hour= 0 , minute= 0 , second= 0 , microsecond= 0 ) print(f "START TIME -
Hi, does anyone know which CPU would be faster for strategy tester: Intel Xeon E5-2690v2, 10x 3,0 GHz (Turbo 3,6 GHz), 20 Threads or Intel Xeon E5-4657Lv2, 12x 2,4 GHz (Turbo 2,9 GHz), 24 Threads Thanks
I’m in the process of learning how to use MT5 with python. My demo account through the broker had a starting balance of £1,000, and it looks like this: account_info=mt.account_info() account_info AccountInfo( trade_mode=0, leverage=1, limit_orders=200, margin_so_mode=0, trade_allowed=True
Hi everyone, There is a fantastic tool for the MT4 called toggle border. This tool makes the light blue edge/frame of all charts disappear (multichart) and thus reduces the view to the most necessary/important thing, namely the chart. I combed through everything to find this script for the MT5 too
Hi, I'm a beginner trader from Norway looking for advice. I started trading XAUUSD manually two months ago with $1100 using TradingView connected to a Pepperstone account. The first month was a disaster, and I lost 35% of my account in a few trades because I didn't set stop-losses. My second month
Hi everyone, I'm trying to program cleanly, what do you recommend for storing trade information and being able to manipulate it until the trade is closed? I'm hesitating between creating a structure type variable , and creating a class with object manipulation to store all this information. thank
Eas not open position when the price reach EMA25 pls help me fix Thanks
Hey Guys,             I have a reasonably profitable EA that always generate large drawdowns during major news announcements but it doesn't have the capability to pause "autotrading". Does anybody know of a good EA that can pause Auto Trading during major news announcements and turn it back on...
Hi everyone. I am new to MQL5 but have managed to create some code that buy and sell as I want but I am having trouble with the closing of the trades. I want the trade to close as soon as the next and oppisite trade opens, can anyone help? TIA #include <Trade\Trade.mqh> #include
Hey guys, I'm quite new to MQL5 so this might be a noob question. When I get my entry signal I want to open 4 positions, each with the same Stop loss but but different Take profits. So I guess my question is how to I open 4 positions and how do I set each position with its own take profit level? I'm
I'm trying to get the upper and lower values from iBand... void OnTick () { double upperBand[]; double lowerBand[]; double range; int handle = iBands ( _Symbol , _Period , 20 , 2 , 0 , PRICE_CLOSE ); // CopyBuffer(handle, which band, period, no. values, where to store)
I'm talking about const members of simple types that are not static (and are not pointers). class CFoo { private : const int i; public : CFoo() { i = 1 ; // 'i' - constant cannot be modified } }; Why is it possible to make members of simple types const? Such a member will not
I want to run OnTick on history in different symbols one after the other Each time the balance must be reset Is it possible to do it via code
Good morning How are you ? I'm looking at the terminal log to debug some of my code for data synchronization between the server and the terminal. Here it is IM 0 09 : 57 : 10.990 (GOLD,M1) History check for GOLD for timeframe M1 FF 0 09 : 57 : 10.990 (GOLD,M1)
Can a function be accessible only to an include file