Expert Advisors and Automated Trading - page 454

hi every body ,iwish if some body to make me an expert ,
Greetings, I am new to MQL5 and would like to know the code for an order management EA that does the following: When a trade is above a certain profit, close the trade and place a new one. When a trade is below a certain loss, place a new trade without closing the original trade. On every loss
Hello, can anyone give a definite information about where to place custom dlls by setup for MetaTrader5 on 32 bit and 64 bit os ? for instance: - on 64 bit os a) program files\...\mt5installpath b) system32 c) users\...\AppData\Roaming\MetaQuotes\Terminal\HEXCODE\MQL5 d) ...? -...
I want release some trade info, like: After a order placed , I will call a http://...../boardcast.php, Is it a way to open URL by code from expert
Hi, I´m looking for a way to read out values of indicators, like RSI or average movement, to try out scripting an expert advisor. Anyone know how to do that? I am beginner/advanced-beginner in mysql, so I´d be grateful for an example script code. Thanks!
MQL4 manual states that: "An Advisor starts to run with every incoming tick for a given symbol. The Advisor will not be launched for a new, tick if it is processing the previous one at this moment (i.e., the Advisor has not completed its operation yet)." My question is it possible to overcome this...
  Error 4802 is killing me  (13   1 2)
I am posting here because I am totally out of ideas. I'm trying to get an EA that I have to correctly call one of my indicators. I have tried every possible thing I can think of, and nothing I do will work. The problem is that when I call IndicatorCreate(), I always get error 4802. Here is the...
Here is the code I used and it's working in OnInit(),but not working in OnChartEvent()... return code is 10013...I get the 4756 error... Why? Please help. MqlTradeRequest request; request.action = TRADE_ACTION_DEAL; request.symbol = Symbol(); request...
Hello Everybody , This is my first forum ever. I never wrote one before on any website. So i apologize if it is misplaced. I have an idea that i am trying to develop. In order for me to progress with it , I need to be able to set the EA to have the ability to open a new position when there is...
  levrerage value  (2)
Hi All,   When in the strategy tester I change the levrerage to 1:500 and 1:100 or any option in the drop down and it has no effect on my profits, why??   MQL Support  told me it is because I dont use the levrerage value in my lot calculation but when searching for...
Ok, I'm having 2 issues, first, when Adjust_sl_ap is true the EA should adjust SL to average price since im scaling in positions this would be PositionGetDouble(POSITION_CURRENT_PRICE) right?? and secondly, when adjust_sl_ap is false it should use a trailing position, but for some reason trailing...
Hi, i want to create a EA which uses the pivot point universal indicator (https://www.mql5.com/en/code/102), with a strategy that buys and sells when price is near the pivot point calculated by the indicator. How can i get the handle of that indicator in MQL5? Or how can i access to the price...
Hello all. I am trying to put together an EA that uses Limit Pending Orders. This is the function used. As one can see, it is the exact same as the function in the avoitenko EA, except ORDER_TYPE_BUY_STOP has been changed to ORDER_TYPE_BUY_LIMIT. The function is only called when the current tick...
Hello All, I am new to programming and have a couple of easy questions. 1. Is it better (or even possible), to have one EA scan for conditions and make trades on many pairs, or do I need a chart window for each time frame? 2. I read somewhere it is possible that if you have two EA's running at...
Is any example code for this purpose. thanks
Hi, I have a short question: Is it possible to use the final balance as optimization criteria?. (not the max balance). Many thanks!
Dear all, I am finding a problem in invoking functions of a C# DLL from MT5 into Win7 64bit; everything runs smoothly into my x86 laptop, therefore I assume there is something stupid I miss, so here is my short story: - Have this nice DLL, doing a lot of cool calculations, to be used into my Expert...
There must be something essential that I dont understand. I have now tried 2 different methods to place 2 trades with different TP-levels. Split position. 1. Just place 2 trades with differen TP-levels. Does not work, both trades ends up with second trades TP 2. Place 2 trades without TP. and...
In MT4's ticket-based system, it was fairly easy to manually close one EA's position if I had multiple EA's trading the same pair on the same account. e.g. EA #1 places EURUSD SELL order for 0.1 lots @ 1.30000, EA #2 places EURUSD SELL order for 0.1 lots @ 1.29000 and EA #3 places EURUSD SELL order...
Running Strategy Tester. I place 2 trades in succesion for the same pair. The only difference is the takeprofit level. In the Journal the result is: 2012.01.08 00:05:50 Core 1 2011.09.21 21:35:40 order performed buy 1.00 at 1.00818 [#4 buy 1.00 AUDUSD at 1.00818]...
What is a simple method to figure out that the last trade done was a loss?
It would be great if it were possible to script execution of metatester, through the CLI. So, one could call the exe, pass it a .set file, and have it back-test a .mqh file and output the results to a log file.. c:\>metatester64.exe /run MyExpert.mq5 /set MyExpertSettings.set /logfile MyExpert.log
I donot know what is this error, can you help me?
my mean the result is like we trade in live account ? then we can believe it.
ike a lot of other people in this forum I am having serious problems understanding what "invalid stops" means (and the infamous 4756 error). Apparently this error is returned when a stop loss or take profit order is too close to the current price, but how close is too close? How is this calculated?...
Hello All, Please feel free to read my posts about brokers API/SDK: 1) MBTrading SDK/API review - http://caapitech.blogspot.com/2011/05/mbtrading-sdkapi-review.html 2) IB SDK/API review - http://caapitech.blogspot.com/2011/12/ib-sdkapi-review.html Regards, Moris oz Algorithmic trading Consulting and
  MQL5  (1)
There are quite a few things to relearn in MQL5. Sometimes its a struggle. But there are also great benefits. One feature i absolutely love is the "struct". It makes returning several different values and data types from a function so simple and elegant. Kudos.
Hello eveyrone (and merry christmas !) I'm really starting with mt5, so I don't have much knowledge. I guess it will appear as a very basic question, but here it is: Let's say I want to create a robot which will will automatically buy EURUSD and then sell it after 1 hour. And then repeat that. How
Creating a new library with a simple test function and use it in an EA does not work now. Some month ago I converted a MQL4 library containing a logging funktion. It still works fine except that it does not work to add new functionality to it. The new function are not found. The log function still...
  Basic Question  (2)
I'm new to using Robots - but I have added 2 Robots to my demo FXCM Metatrader 4 platform (Best Secrets EUR/USD & GBP/USD) - I have smiley's in the top right hand (chart)corners - but thet are not trading? In the navigator both robots are greyed out ? Any advice please?