Hi there !
Please excuse my ignorance as I am trying to migrate to MT5.
I downloaded Include, Indicator and Expert files from this page: https://www.mql5.com/en/code/1190.
The "Include" files I saved to this folder: C:\Program Files\MetaTrader 5 - Alpari UK\MQL5\Include
The "Indicator" file I...
hi I'm back testing a moving average Cross over and for three quarters of the backtest its really profitable but then in the last quarter it suddenly sells when it should buy and vice versa. How can it do this ?
Hello
I'm new to MT5 and never used automated trading before. I'm quite intriged by the potential and decided to makae the leap.
I've imported quite a few EA's but when I watch them perform in the Strategy Tester Window they never buy or sell at the right times.Has anyone encountered something...
I selected M5 as the time frame to execute my EA. Strategy Tester opened the M5 chart, but the candles in the chart are daily. I held my cursor over three consecutive candles so you could see the info
When I am writing the code for an expert advisor, how do I apply an indicator on the data generated by another indicator? for example, putting bollinger bands on RSI. because in the iBands functions, you need to put the symbol name. Any help is greatly appreciated.
Hello, I Have times a EA code "found" and thought him easy to convert. Similarly Martingail (excluding hedge). Of the original IS hardly remained. My code makes what he wants. And driving me nuts. Do I think about it logically correct have made, But probably not structural WILL die cast. Would
I want to try to count wave patterns in my EA and see the wave counts on the chart. Do I need to create a custom indicator and attach that indicator to the template file and access the custom indicator in the EA or can I call a function to draw an object on the charts directly from the EA?
I have...
When I test my EA in different time frames, the chart that is produced does not have the same set of indicators. I have a template created that has MACD, Bollinger Bands and moving averages. When I run my EA in M5 or H1 time frame, only the indicators I have in my template are displayed. When I...
Hi all, After a lot of reading, I think I'm ready to post my first message. Which contains a probably easy question but I can't seem to be able to solve it, and after several hours of searching I decided to shoot it out here :) Anyhow, I'm trying to make an EA that stores yesterdays range , goes...
Hi,
I need to write a function that returns 2 file handles, which are just ints, so I thought to declare the function like
int[] getFileHandles();
but MT5 didn't support returning an anonymous sized array, and wouldn't let me return a pointer to it or even to specify the size like
int*...
I have a doubt about how an stop loss order is implemented.
Example: Imagine I have a Stop Loss sell order on EURUSD at 1.32045 (well below the current market). The market reaches 1.32045, the order fires, but without time to complete the full quantity, the market jumps to 1.32050, and stays there....
I have been coding for quite some time, but today I learned something new.
For all of the experienced programmers out there, this maybe pretty obvious, but for anyone just learning, please read.
When calling an indicator within an EA like this example, you assign a handle of type int:...
Hi,
I got some troubles calculating the StopLevel - here is my code:
double currPrice = SymbolInfoDouble(_Symbol,SYMBOL_ASK);
double point = SymbolInfoDouble(_Symbol,SYMBOL_POINT);
double stopLevel = SymbolInfoInteger(_Symbol,SYMBOL_TRADE_STOPS_LEVEL) * point;
double stopPrice = currPrice +...
When I add AutoDayFibs (2).MQL4 Source file in indicator folder the meta trader software will be hang... I can use win7 sys. Pls give solution on this error...
Is it possible to call the tester for optimization from the EA?
What I want to do is re-optimize every weekend after the market has closed. I can use
MqlDateTime str1; TimeToStruct(TimeLocal(),str1);if (!selfoptimize) return;if (str1.day_of_week!=selfoptimizeday) return;
to check for the...
Hi everyone, So I am in the process of creating an automated trading program and would really love to get your input. This is where I began trading and so I thought I would get the opinion of the mql5 community first. It is just a short 8 question survey to help me get started. I would really
Need know when a deal is done, if: (1) it created/scaled in, or (2) closed/scaled out, or (3) reversed position.
As I understand it DEAL_ENTRY_IN would indicate if (1); DEAL_ENTRY_OUT would indicate if (2); and DEAL_ENTRY_INOUT if (3).
However, no matter if I open a position, close, scale, or...
Hi all.
Is it possible to detect automatically (script) the switch period between winter/summertime in America when i'm located in Europe?
In the United States, Summer Time begins on the second Sunday inMarch and reverts to standard time on the first Sunday in November.
In the European...
i have write the code like this :
void OnTick()
{
// some codes...
if(!PositionSelect(_Symbol))
{
CTrade trade;
trade.PositionOpen(_Symbol,ORDER_TYPE_BUY,0.1,
SymbolInfoDouble(_Symbol,SYMBOL_ASK),...
Hello,
on MQL4 it was very easy to get the value of Bollinger Bands
double Upper = iBands(NULL,0,20,2,0,PRICE_CLOSE,MODE_UPPER,1);
double Middle =iMA(NULL,0,20,0,MODE_SMA,PRICE_CLOSE,1);
double Lower = iBands(NULL,0,20,2,0,PRICE_CLOSE,MODE_LOWER,1);
hot is the same on MQL5...
I'd like to protect my Code both when showing it to someone and when sharing the strategy with someone. Is there any way to do this? Also, the metatrader language has to be a psuedo-language. Is there any way to see the underlying C# code? At least I think it must be C#. I've also been able to...
Tried to building EA based on recommended usage of the most commons indicators such as ac, ad, adx, even combination of ma and par
RESULT
with the setting of equal pips to win and larger pips to accomodate the possibility that favours the movement(prevent early stop loss)
with the recommended...
extern double MaxSpread = 3;int start() { int SellOrder = 0; if(MarketInfo("GBPUSD",MODE_SPREAD) < MaxSpread) { SellOrder = OrderSend ("GBPUSD",OP_SELL,1.0,MarketInfo("GBPUSD",MODE_BID),5,0,0,""...
Hello,
Have a position for Symbol x and need to know the closes StopLevel that would be accepted by trade server.
How to do this ?
Thank you
I want my EA to close trade based on the change,lets say drop in bar of an indicator compared to the previous one.
how can i set the condition?
and if there is a manual can anyone link me? confused here
Hi Guys
I was wondering if anyone knew how to have custom indicators remain on chart after backtesting?
Hi all
Do you know how to download ticks/data for currency pairs and major indices for Alpari Pro?
Thank you
Results are not always shown and the Journal message is that the pass was not significant.
Please, please show me all the passes, good or bad, significant or not, because it helps me to learn.
In documentation, there is an example with import of stdlib.ex5 to use ErrorDescription like in MT4. But I can't find stdlib.ex5 or stdlib.mql5 anywhere.
Do you know if it's stille exist or an alternative to ErrorDescription() ?
Thanks
i have translate this good tool for coding string script for obsfucation.
but i don t why i have this error in the log of editor at the compilation "implicit conversion from 'number' to 'string' CrypTool_Mt5.mq5" ?
and the script converse good running !
#property script_show_inputsinput string...

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.