Pick one...
ERR_INVALID_STOPS 130
Stops are too close, or prices are ill-calculated or unnormalized (or in the open price of a pending order). The attempt can be repeated only if the error occurred due to the price obsolescense. After 5-second (or more) delay, it is necessary to refresh data using the RefreshRates function and make a retry. If the error does not disappear, all attempts to trade must be stopped, the program logic must be changed.
ERR_INVALID_STOPS 130
Stops are too close, or prices are ill-calculated or unnormalized (or in the open price of a pending order). The attempt can be repeated only if the error occurred due to the price obsolescense. After 5-second (or more) delay, it is necessary to refresh data using the RefreshRates function and make a retry. If the error does not disappear, all attempts to trade must be stopped, the program logic must be changed.
[quotephy 12.02.08 00:17
Pick one...
ERR_INVALID_STOPS 130
Stops are too close, or prices are ill-calculated or unnormalized (or in the open price of a pending order). The attempt can be repeated only if the error occurred due to the price obsolescense. After 5-second (or more) delay, it is necessary to refresh data using the RefreshRates function and make a retry. If the error does not disappear, all attempts to trade must be stopped, the program logic must be changed.
][/quote]
phy, you did not even read the output of the expert published above!
Pick one...
ERR_INVALID_STOPS 130
Stops are too close, or prices are ill-calculated or unnormalized (or in the open price of a pending order). The attempt can be repeated only if the error occurred due to the price obsolescense. After 5-second (or more) delay, it is necessary to refresh data using the RefreshRates function and make a retry. If the error does not disappear, all attempts to trade must be stopped, the program logic must be changed.
][/quote]
phy, you did not even read the output of the expert published above!
I did.
I can't tell if your stops are un-normalized.
Can't tell if you have current bid/ask.
You showed output, not code.
I can't tell if your stops are un-normalized.
Can't tell if you have current bid/ask.
You showed output, not code.
On Market execution I have this message:
Invalid ticket for OrderModify function;
Here are the codes:
ticket = OrderSend(Symbol(),OP_BUY,Lots,Ask,Slippage,0,0,"EA"+Symbol(),MagicNumber,0,Blue);
OrderSelect(ticket,SELECT_BY_TICKET);
OrderModify(OrderTicket(),0,OrderOpenPrice()-StopLoss*Point,OrderOpenPrice()+TakeProfit*Point,0,Blue);
Thanks
FXman
Invalid ticket for OrderModify function;
Here are the codes:
ticket = OrderSend(Symbol(),OP_BUY,Lots,Ask,Slippage,0,0,"EA"+Symbol(),MagicNumber,0,Blue);
OrderSelect(ticket,SELECT_BY_TICKET);
OrderModify(OrderTicket(),0,OrderOpenPrice()-StopLoss*Point,OrderOpenPrice()+TakeProfit*Point,0,Blue);
Thanks
FXman
Thanks Rosh.It is working.
What is the different:
bool result = OrderModify(OrderTicket(),0,OrderOpenPrice()-StopLoss*Point,OrderOpenPrice()+TakeProfit*Point,0,Blue);
...
bool result = OrderModify(OrderTicket(),OrderOpenPrice(),OrderOpenPrice()-StopLoss*Point,OrderOpenPrice()+TakeProfit*Point,0,Blue);
instant 0 is OrderOpenPrice().
FXman
What is the different:
bool result = OrderModify(OrderTicket(),0,OrderOpenPrice()-StopLoss*Point,OrderOpenPrice()+TakeProfit*Point,0,Blue);
...
bool result = OrderModify(OrderTicket(),OrderOpenPrice(),OrderOpenPrice()-StopLoss*Point,OrderOpenPrice()+TakeProfit*Point,0,Blue);
instant 0 is OrderOpenPrice().
FXman
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
2008.02.11 00:29:14 ReportsTrader GBPUSD,H1: delete #11716966 sell stop 0.20 AUDNZD at 1.1371 sl: 1.1405 tp: 1.1325 ok
2008.02.11 00:24:20 ReportsTrader GBPUSD,H1: open #11716966 sell stop 0.20 AUDNZD at 1.1371 sl: 1.1405 tp: 1.1325 ok
2008.02.11 00:24:16 ReportsTrader GBPUSD,H1: open #11716965 buy stop 0.20 AUDNZD at 1.1405 sl: 1.1371 tp: 1.1451 ok
Buy and Sell pending positions are placed either side of the market, when the market reaches one of them then the other is cancelled, this is working. When the expert looks after it's little profit then OrderModify() prints error 130.
I have spent 2 weeks on this problem, another pair of eyes please.