Expert Advisors and Automated Trading - page 120

To post a new topic, please log in or register
  Error (1)
Hello My EA made a error like: modification of order #63963017 sell 0.12 GBPCHF at 1.30359 sl: 0.00000 tp: 0.00000 -> sl: 0.00000 tp: 1.30249 failed [Common error] It failed to set TP how can that be normally it works just fine ! I was friday evening and it did it a couple of times... Any ideas?
Hi, I'm learning mql5 and I'm having a problem with CopyBuffer. When I change the count parameter of CopyBuffer it shows me different values and that is affecting my entry points Please, see below: int OnInit() {   sma3_handle=iMA (Symbol(),PERIOD_M5,3 ,0,MODE_SMA,PRICE_CLOSE); } void OnTick() {...
Wohoo .. sorry for the title, but I don´t know how to explain in one sentence what I am looking for ;) Well, in MT4, when a position is closed partially, MT4 creates a new position with a new ticket. The partially closed one keeps alive, is tagged as closed and the commend field contains an...
So I have this EA that displays weird characters for the options after loading, and also in the source file.. extern string ÍÀ×ÀËÜÍÛÅ_ÏÀÐÀÌÅÒÐÛ = "ÍÀ×ÀËÜÍÛÅ ÏÀÐÀÌÅÒÐÛ"; extern int Ìàãèê = 11111; extern int Òèï_Ëîòà_0_1_2 = 2; extern double Ïðîñêàëüçûâàíèå = 5.0; extern string ÏÀÐÀÌÅÒÐÛ_ËÎÒÀ =...
[Deleted]
Hello ,  I'm making an Expert advisor including MACD In the code I depend on the value of Signal and Main line ( Histogram) in MACD in the bar 0 and bar 1 . it works perfect but sometime it comes out with strange values as -7.835123405921764e-05  , I print out those values so you can see in the...
Hi everybody, in my EA I use a lot of indicators. But by default, all used indicators automatically appear on the screen. Is this possible to switch them off and especially only some of them.
How do I place a new buy or sell order in code if conditions are met? I've tried this, but no results:  CTrade trade;    MqlTick Tick;        MqlTradeRequest myRequest;    MqlTradeResult myResult;    ZeroMemory(myResult);        myRequest.action = TRADE_ACTION_DEAL;    myRequest.type =...
Hi I want to get time portion out of datetime.. please help ie, 2017.0.15 15:30:00 to just 15:30 The idea is to close trades after 15:30. Please let me know how to achieve this. Thanks
Подозрительная финансовая активность пользователя 'goldenjet': +99, fail P to ' goldenjet ', email 'accounting@reagormedia.com'!='admin@uswhss.com'
Okay so I'm very new to this and have very little understanding of trading and I'm just helping someone else out. I have a very simple task: to open a new sell or buy position if certain conditions were met, but I can't seem to work this out. I've tried googling but nothing came out. I've tried this...
in this EA my problem is that it moves the TP but doesn`t set  the SL and in the journal the value for stoploss is ZERO please help me with this. //+------------------------------------------------------------------+ //| Expert tick function                                             |...
Hi All If someone could help me achieve the below it would be great; In Ontick() I have some indicators, 1. when indicators generate Open Signal I want to book a trade and create a position 2. When indicators generate Close Signal I want to close position. Please help
[Deleted]
I think that this code has no errors. //Codes From controlerrors.mqh  //_CountErrors is constant 150. // Error Line is 85,10 (Structure Array Error) ArrayResize(Errors,_CountErrors);  85   Errors[0].code = 10004;Errors[0].desc = "Requote"; But my ea( containing controlerrors.mqh) cannot init after...
How to call a function after each 45 second? Period of call function = 45 second
Hello, hope i am posting in the right topic. I've been trading Binary Options(never tried Forex) for some period of time, on other side i'm happy that i've learned many things from it, but in the other side, the profit results we're none(let's not go deep in my history, binary options in my opinion,...
Hey, When i'm going to test the EA TMA this happens in my diary;  2017.09.12 02:27:43.045 Core 1 2017.09.11 23:41:00   CTrade::PositionOpen: market buy 0.20 EURUSDmicro sl: 1.18938 tp: 1.20438 [invalid fill] For what i have searched the error is in the codebase of the EA but i don't have acess to...
Hi, am programming in C# and wants to use my code to backtest RSI settings that I then wish to program in MQL.  DOES THE CALCULATION LOOK CORRECT BELOW? I'm using SMA-method for the calculation. In the example below I will have a setting of RSI 5 1) Calculate ChangeUp and ChangeDown for each bar by...
Hi My adviser does not want to trade. It compiles without errors but for the love of me doesn't open or close a trade. What an i doing wrong. Take note this is my first attempt so i might have missed some functionality. Any advise would be appreciated.
Hi ! Here's the error message I get using and indicator on a EA. It worked perfectly, then show that. Unfortunately, I restarted the terminal so I can't copy past the exact log. Anyone has experienced such an error ? PS : it worked 'til now.
I have a problem with the condition for example to buy orders. I want that the EA is opening an order when following conditions are met: (GoLongSandR=true and(Pattern1=true or Pattern2=true or Pattern3=true) That means always SandR + Pattern(s). But it is opening orders when any of theses Patterns...
Hey, does anyone know if this EA are already made: In the EA you set a price that says to the EA that "if price closes beyond this point (close above if selling, and close below if buying), then the trade should exit. You should also have the possibility to set timeframe in the EA (if it closes on 1...
Tenho m EA que disparou a dar ordens sem TP, em um único par, mesmo tendo ordem para dar no maximo 20 ordens. Preciso de uma linha de programação que limite o numero de ordens por magic number, para reforçar segurança do EA Desde ja agradeço
Hi All, Kindly let me know if it is possible to write an MQL5 code to automate this task. A. Download csv File from http://abcx.com B. Save or replace it in \MQL5\Files folder I have tried with #import "shell32.dll" and #import "wininet.dll" but seems not able code them to work properly. Any working...
Hi There, Can you kindly assist me with how to obtain two previous ZigZag Swing Dates?
Hi, I have coded an EA that is guessing future trend. I would need to draw that future trend on the chart by displaying a zig zag line shifted to the right of the chart. From that post, the guy is asking about "How to draw something in future time coordinate ?" for indicators. I can see that it is...
I wonder why last value of MqlTick return 0.0? Here the trivial code void OnTick()   {    MqlTick last_tick; //---    if(SymbolInfoTick(Symbol(),last_tick))      {       Print(last_tick.time,": Bid = ",last_tick.bid,             " Ask = ",last_tick.ask,"  last= ",last_tick.last);      }    else...
Hi coders. After running a walk forward analysis, lets say my 'walk forward efficiency ratio' is acceptable. After that I'll have x-period optimized inputs. Question: which inputs from which period do I need to consider to run my EA no live account? Maybe the inputs of the period with the best...
Hello all, i am new to MT. I am wondering is it possible to write a code so that i can plot the chart timeframes which are not available as standard. For example, a single candle which is equal to 2 day, 133min, 7hour etc? Thanks for your replies.
Hi, I am having trouble with my MA Crossover EA. I wanted to enter sell positions only when the price (that is set up as 1 day MA) crosses 14 days MA from above.    extern int FastMA = 1;   extern int SlowMA = 14;   extern double LotSize = 0.01;      extern int ticketSell;int OnInit()  {...
hi guys, I'm a newbie with no programming background. I start to self learn writing EA by reading other free EA online and also the Help Manuel in the EA editor. The progress is ok so fair. However, some times I face some fundamental problems that I can't understand. I hope that u guys can help me...