MQL4 and MetaTrader 4 - page 865

To post a new topic, please log in or register
Hello, when trading day is over I sometimes need to analyze past data and look at them in detail (in order to improve my trading approaches). The way I am doing it now is, in fact, bloody. I am letting my trading platform list the prices for specified period of time like... int start()     {...
Hi i wonder if anybody has experienced this problem with iMA. i am creating indicators with two different time frame but when im running it, it doesn't work I am getting the MA from the open chart and not from the time frame that in the code i want it to work on 15 min and 30 min.please whats wrong...
Hello out there, I just installed MT4 to my HTC touchpro smartphone, i need to load 4 settings of the same indicator in the same indicator window on my chart but i have not been successful at doing this. Once an indicator is loaded on an indicator window other indicators will load in the same window...
Is it possible to run a strategy that places several orders on the strategy tester? When I want to test my strategy it only has a dropdown box where I can only choose one instrument and it will only give me feedback for one instrument as opposed to all the instruments collectively
hi, 1- how can I set below expert advisor in my fxopen navigator? I like sometimes it trades with more than 0.1 lot. 2-do you know best currency-pairs & timeframe for this ea? 3-it opens & closes positions itself but after open a position, there aren`t any stoploss or takeprofit on the terminal,...
see this example....thanks
Please help advise how I can save some price values of a bar or an identified range. E.g lets assume my choice bar is 10.00GMT H1-bar, and I wish to save the vales of High and Low at 11.01, and I will like to use these values throughout that day for decisions in my EA. Or I probably I wish to pick...
Hi I have a profitable EA that gain a lot in the back testing, it opened around 2000 orders and seems like its doing good however there were some cases when it didnt open orders in the back testing, so i tried to check it for a while on my demo account and in order to compare the results with the...
I using this code string row="";   query=StringConcatenate("SELECT id FROM table1");   length=StringLen(query);   mysql_real_query(mysql2,query,length);   int result = mysql_store_result(mysql2);   int numOfRows = mysql_num_rows(result);   Print("numOfRows:",numOfRows);   for (int...
I use the MT4 platform from Pro Brokerage. The simplest operation, OrderSend(Symbol(),OP_SELL,1,Bid,3,0,0,"",MAGICMA,0,Red), returns 133(trading is disabled) all the time. Who could help on this? Thank you.
I am brand new to MT4. I am playing with some simple commands such as Print ("4"); It is working. But if I change it to Print ("3"); and save and exit and run the script it still returns a 4. Only after I close and reopen the platform will I get a 3 returned. What is the problem here?
Is there a function in MetaTrader that closes all orders that are open and pending?
FREE VOLUME INDICATOR
hi im looking for a linked program to a trading platform to trade for me EUR USD a program that buys and sell for me automaticly at a set price that i tell it to. Once triggers price and once it hits price again long or sort it will keep on hitting that possition till i cancle that fixed price does...
A few questions regarding ticket numbering and OrderSelect()behavior: 1. Is it guaranteed thatorders opened have ascending ticket numbers? So for example - if order x wasopened AFTER order y, is it guaranteed that ticket x > ticket y? 2. Regarding 1 – is this a broker specific behavior...
Hi I have this code as part of a function in my EA, basically it looks for breakouts of the upper and lower bands from the start time (bar) thats is specified earlier in the in the EA, up to the current bar plus 3. By defualt the fucntion returns an empty_value unless I break out the bands is...
hello guys, need little help here.. I'm not a programmer and having a little issue with this code; int cnt = OrdersTotal(); for (int i=0; i<cnt; i++) { if (!(OrderSelect(i, SELECT_BY_POS, MODE_TRADES))) continue; if (OrderSymbol() != Symbol()) continue; //if (OrderMagicNumber() !=...
Im a newbie coder so bare with me, written a code that buys when short liner wighted MA crosses above long liner wighted MA and Psar showing an uptreand and sells when when long liner wighted MA crosses below short liner wighted MA and Psar showing an downtreand. but it only opens buy possitions and...
If I want to risk buying lots with 1% of account each trade, how do I code that. How can determine how much lots to place the order for if my account is 100,000. so 1% is $1000. and I want to buy $1000 worth of lots. Would the same code work if I used the EA on micro-account? How do I go about...
hi guys can im new to EA Programming thus can any one specify a function or a algorithm to calculate number of bars elapsed since 2 successive loosing trends thankz
Hello, I'm a newbie in MQL4... I managed to code some up and down arrows on my graphs with buy & sell signals... Unfortunately, when it runs live, the signal are wrong because they are calculated "live" while i need them to be calculated on the bar 1 as soon as bar 0 starts. So on the last bar as...
how do I program my ea to place the order on the open of the next bar only.? The tester is opening the order 0.00073 above the open tick... I want it at the open tick. any help if appreciated.
WHY is it when I save a template on MT4 using Windows 7 O/S that the template is locked and cannot be passed/copied? Thanks George
Hi Pros, When I test the EURUSD history data, there is no error: OrderSend(Symb,OP_BUY,0.2,Ask,2,SL,TP); When I live trading, it always reports error 138. It still opens the order but reduce the lots from 0.2 to 0.12. Could anybody tell me why this is happening? Should I make the...
APeng
Hello everyone! I need the values of MACD calculated like they are in the ZeroLAGMACD indicator "ZeroLAGMACD calculates on formula:" ZeroLAGMACD(i) = (2*EMA(Close, FP, i) - EMA(EMA(Close, FP, i), FP, i)) -(2*EMA(Close, SP, i) - EMA(EMA(Close, SP, i), SP, i)); ZeroLAGMACD Signal(i) = 2*EMA(ZeroLAG...
Forgive me if this question has been answered 1000 times and I just couldn't find it. However, I want to initiate a download of the MT4 historical and orders reports using only the investor ID, the same way as myfxbook.com or mt4i.com does. I don't want to use any EA based method as I am running...
If I want to risk 1% of my account for a trade, is there any code or function to calculate lot size
Hi everyone, I'm trying to run a backtest on an EA (using offline charts), and then call a routine from the deinit() function that will extract certain information about each trade generated in the strategy tester. (On a side note - specically, I am working on getting the drawdown (and run up)...
Hi, I would like to draw eurusd & gbpusd charts in same chart. It is possible with mt4 ? Tx.
Hi, If anyone need. how can i to know the last open trade status ? void LastOpenTrade_function(int nb) {                      for (int cnt=0;cnt<OrdersTotal()-nb;cnt++) {         OrderSelect(cnt, SELECT_BY_POS, MODE_TRADES);              if (OrderSymbol()==Symbol() && OrderMagicNumber()==Magic)...