This forum is in read-only mode now. You may discuss your questions on forums of MQL4.community and MQL5.community
OrderSend FailedBack to topics list |
|
russb
2005.04.21 17:04
I have an expert advisor running with just one line of code:
OrderSend(Symbol(),OP_BUY,1,Ask,3,Ask-20*Point,Ask+2*Point, NULL, 0, 0, Aqua); What's suppose to happen is that it should keep buying until I'm broke. I'm just testing it this way because this function is not being executed by MetaTrader4. |
|
Slawa
2005.04.21 17:32
1. Check last error
2. I think your takeprofit level is wrong |
|
russb
2005.04.21 17:53
I was trying to send an order with a take profit level exactly 1 pip above the opening price. It seems that MQL grants orders when take profit levels are above 10 pips. Am I right?
|
|
Slawa
2005.04.21 18:33
it depends from server settings. to know exactly stoplevel value call MarketInfo(Symbol(),MODE_STOPLEVEL)
|
|
CoenWillemse
2005.04.22 00:30
Hi Slawa,
Regarding your comments above - are you saying that the function call MarketInfo(Symbol(), MODE_STOPLEVEL) would provide me with the minimum distance in points that a SL/TP price must be set from the market price? |
|
Slawa
2005.04.22 11:09
Regarding your comments above - are you saying that the function call MarketInfo(Symbol(), MODE_STOPLEVEL) would provide me with the minimum distance in points that a SL/TP price must be set from the market price? yeah |
|
CoenWillemse
2005.04.28 02:33
Great - thanks for that Slawa!
|
Download MetaTrader 5 (450 Kb, web installer) — a new terminal for financial markets
