Expert Advisors and Automated Trading - page 49

To post a new topic, please log in or register
Hi, is there any way to compare the results from our Expert Advisor with the "buy and hold" alternative. That is, if we buy at the first position opened by our tester and then we just hold that until the end of our test (this is useful because if we are testing a bullish market we could think our...
I'm building a basic EA. I would like to enter a long position on the high of the last x hourly candle. Is the timeframe of the chart overruling the timeframe set on the EA? If in the code I calculate the high on the hourly candle (double HighEntry = High[iHighest("EURUSD",60,MODE_HIGH,48,1)]), but...
I have been using the code below to prevent portions of my code from executing more than once per bar. How can I hard code a specific duration, say 5 minutes?Int BarsCount = 0; int start(){ if (Bars>BarsCount) { //executed only once per bar BarsCount = Bars; } return(0);}Please...
Before i post a job i want to know if this is even possible. Can an EA take external triggers?  For example i use Sierra Chart to plan all my trades and am able to make my own alerts and they can be set to .wav files or to sent an email or SMS. Is it possible to create an EA with some dummy .wav...
Hi! In C programming language, one way to swap numbers is: #define swap(a,b) (a=a+b;b=a-b;a=a-b;) How can we write this in MQL5?
>_< all the procedures the EA performs to copy large quantities of buffers and prices, works fine in demo mode. BUT the same procedure fails each and every time in tester. how to copy large number of buffers/prices in tester successfully ? (~ 350,000 buffer doubles) I guess the problem is, my code...
I want to write a code (for an advisor) which closes all open trades at the end of the trading day. So for example if the market for US stocks closes at 16:30, all open APPLE orders must be sold at something like 16:29. I tried to look this up on the internet but I couldn't find any specific answers...
Some time ago I had problems with MySQL and 64 bit windows. I solved it by using a 32 bit MT5 on my computer. It seems that I have gotten into some similar problem or possibly a problem with libmysql.dll Is there a 64 bit version of libmysql,dll? Dont seem to find one Tried to download a 32 bit...
Dear All, ACCOUNT BALANCE:10000. 00 USD Tried to place an oder through EA. CTrade::OrderSend: instant buy 10.00 EURUSD at 1.27443 tp: 1.28443 [not enough money] Got an error:not enough money why? please advise.
Do someone have some EA based on this Indicator? "SSL Fast Ba"
why does it shows up dpo to the chart so many times?? And what do you think is wrong? #include <Trade\Trade.mqh>CTrade   trade;void OnTick()  {double DPO [];double Ask=NormalizeDouble(SymbolInfoDouble(_Symbol,SYMBOL_ASK),_Digits);double Bid=NormalizeDouble(SymbolInfoDouble(_Symbol,SYMBOL_BID)...
how to adjust inputs in ea like automatically open trade etc
Hello all, I'm writing a EA similar to Martingale. But I encounter a problem while I want to re-calculate the "take profit" for all of my current orders. Here are the processes, 1. I set up the target total profit would be 10 USD at beginning before any order is placed.  2. Now, the 3rd order is...
Hello, I want to know can I subscribe my own signal from another broker? My situation is I have 2 trading account from 2 different brokers. Let's say Broker A and Broker B. I already register my signal from Broker A and mark it as Private. I can see it in My Signal page. How can I subscribe to...
Good day great developers, I would like to know How to make the demo Ea strategy tester to work only for few days??? I downloaded a demo of a certain product that demo worked only one day but when I downloaded mine it kept on working until today (1 Year after). I would like to know how to make to...
Hi everyone,  I just try to select the order ticket of largest lot order from my current trading pool, buying and selling. From some of sample just write like following, but as my understanding, it just return the random ticket rather than largest one.  Is anyone could advise me this is right or not...
Hi there, Im trying to set up a WebRequest in an Expert Advisory, wheras the server needs ~5-10 min to come up with the response. Even though I set the timeout to 3600 seconds, I get a "read timeout" after exactly 10 seconds. The following code can be used to reproduce the behavior for MT5 Build...
Hello everyone, thank you for checking my post. Just like the title says, can someone please help me with it? I've been looking on internet, but EA for MT5 is pretty hard to find. What I need is a DAILY TARGET EA, which has function to disable all other EA from opening position after our total...
Hello to all. I would set the stop of an open position to breakeven, but I'm doing something wrong. Look at the code please and leave a comment if you find out the mistake. This is a part of the entire EA: #include <Trade\Trade.mqh>CTrade trade;#define EXPERT_MAGIC 123456double PatternTP2=0;ulong...
  Refund (1)
Does MQL5 have a refund policy? In case person wants to unsubscribe a signal within lets say a week?
the strange thing is, the expert just did well in testing, it was able to trade in tester without problem. now no matter what I do, it pops a  [trade disabled] error each time EA tries to open a position. trade disabled in tester ??? how ? and why it happens suddenly, without changing anything ?...
Hello all I'm thinking about getting a home server (probably second hand) for heavy backtesting, to take advantage of e.g. the Intel Xeon's large core and thread count. Two questions: 1. If I buy a server with two or more CPU's, each with several cores, will MQL5's optimization engine use both CPU's...
Hello everyone,I have a small problem with my EA, I would like him to close the winning position only on GBPUSD.but now he closes the winning position on all the instruments. can you help me please.here is the...
سفارش کپی کردن در انتظار سفارش notstop ... sellstop..buylimit .. .selllimit در حساب من کپی نمی شود    please guide me  please guide me  
MetaTrader 5 Version: 5.00 build 1881 09 Jul 2018 Server: GenesisMarketsLP-Demo Symbol description "Trade" is "Full access" But SymbolInfoInteger(Symbol,SYMBOL_TRADE_MODE) returns SYMBOL_TRADE_MODE_DISABLED
MT noob here so be gentle lol. I downloaded tickstory to add some history to my MT4. After exporting to Mt4 it downloaded the chart and said complete. After closing and restarting MT4 I cannot do a single backtest on any pair. It just stops as soon as I press start. Also scrolling back through...
Since a time I've been thinking about to build an EA template sothat I don't need to write the whole codes but just the business logic. Here is my code: //+------------------------------------------------------------------+//|                                                   MyTemplate.mq4...
Can anyone recommend (from their experience) a decent EA to run? I’ve only got a small account (will demo first anyways). There’s so many to choose from on MT4. But I’m sure a lot of scams too.  So far I’ve liked the backtests I’ve done for <Deleted>. Anyone use and can share an experience with...
Olá preciso de um robo forex com alta precisao nas configurações, preciso deixa lo abrindo ordens e fazendo martingale a cada 800 pips, e fechando o tp a cada 1.000 pips,, como opera micro conta se torna saudavel as negociações sabendo que para ficar perigoso tal par teria que chegar a 8.000 a 9.000...
Hello, I am trying to solve this puzzle: how to test EA on several pairs same time? EA opens orders on each pair standalone, checks profit/loss every second, finds most negative order on certain pair and closes it with profits from other pairs. No platform, MT4 orMT5, covers single EA working on...