Error 4107 Mql4
Contents |
04:42 During a back test I receive the error message 'OrderSend error 4107 .... invalid price 1.39103000' in the Journal tab. I bracketed the suspect function with 2
Error 130 Mql4
print statements as shown below Print("Ask1=",Ask); ticket=OrderSend(Symbol(),OP_BUY, user_lots, Ask, slip, stoploss, takeprofit, mql4 ordersend error 131 EA, MagicNo, 0, Blue); Print("Ask2=",Ask); The printout from the Journal tab is shown below. The Ask price is 1.391 on
Mql4 Getlasterror
both sides of the OrderSend function according to print statement. However the function is returning an error with Ask price 1.39103000. I am stumped. What is causing this? 2009.08.03 20:33:28 2009.06.16 15:00 mql4 error 1 FxTriggerTrader_EU EURUSD,H1: Ask2=1.391 2009.08.03 20:33:28 2009.06.16 15:00 FxTriggerTrader_EU EURUSD,H1: OrderSend error 4107 2009.08.03 20:33:28 2009.06.16 15:00 FxTriggerTrader_EU EURUSD,H1: invalid price 1.39103000 for OrderSend function 2009.08.03 20:33:28 2009.06.16 15:00 FxTriggerTrader_EU EURUSD,H1: Ask1=1.391 note: I downloaded the history file from MetaQuotes history center. That may be irrelevant.
similar OrderSend in backtest mode what is "no error" exactly? Closing an open order after 15 minutes Using Neural Networks mt4 ordermodify error 1 In MetaTrader limit order help required please 1391 cloudbreaker 2009.08.04 05:02 # Looks like you are using 5 digit history data when 4 digit data is expected due to the parameters that have been set whilst you've had that MetaTrader instance connected to a broker. Try swapping "Ask" for "NormalizeDouble(Ask,4)" and let me know how it goes. CB similar NormalizeDouble functionDetecting if between trend linesEasy fix for OrderModify error 1 problem (trailing stops)Invalid Stops Error on live accountERROR 130 MYSTERY 58 SquareRoot 2009.08.04 05:03 # SquareRoot: During a back test I receive the error message 'OrderSend error 4107 .... invalid price 1.39103000' in the Journal tab. I bracketed the suspect function with 2 print statements as shown below Print("Ask1=",Ask); ticket=OrderSend(Symbol(),OP_BUY, user_lots, Ask, slip, stoploss, takeprofit, EA, MagicNo, 0, Blue); Print("Ask2=",Ask); The printout from the Journal tab is shown below. The Ask price is 1.391 on both sides of the OrderSend function according to print statement. However the function is returning an error with Ask price 1.39103000. I am stumped. What is causing this? 2009.08.03 20:33:28 2009.06.16 15:00 FxTriggerTrader_EU EURUSD,H1: Ask2=1.391 2009.08.03 20:33:28 2009.06.16 15:00 FxTriggerTrader_EU EURUSD,H1: OrderSend erPage Last Post Printable Version Similar Threads Help with "OrderSend error 4051" 12 replies Please help with this EA - Ordersend error 130 11 replies Ordersend 'error 130' -
Error 4051
problems 1 reply Illogical OrderSend error 4 replies OrderClose error 4107 1 ordermodify error 4051 reply Platform Tech / Reply to Thread Subscribe 1 Attachments: OrderSend error 4107 Exit Attachments OrderSend error 4107 Post
Error 4108
#1 Quote First Post: Jun 26, 2008 9:22pm Jun 26, 2008 9:22pm ravster | Joined Jun 2008 | Status: Member | 31 Posts Hello, I'm trying to code this really https://forum.mql4.com/24655 simple MA cross system, and am getting a 4107 error message when testing the system. I get a whole list of the following message in the tester's journal --- 2008.06.26 21:15:14 2008.06.24 23:45 Simple+MA+cross EURUSD,M15: OrderSend error 4107 2008.06.26 21:15:14 2008.06.24 23:45 Simple+MA+cross EURUSD,M15: invalid stoploss for OrderSend function --- I realize that there are other ma cross systems out there, and http://www.forexfactory.com/showthread.php?t=93519 the reason I'm doing this by myself is too learn MQL4. The OrderSend command seems to follow the requirements, I've even used NormalizeDouble(), but I just don't seem to be able to figure this one out. Thanks for the insights, Ravi Attached File Simple+MA+cross.mq4 2 KB | 286 downloads Post #2 Quote Jun 26, 2008 9:26pm Jun 26, 2008 9:26pm charlinks Joined Jul 2007 | Status: Neural Network Trainer | 389 Posts instead of SL and TP you need to use SL * Point and TP * Point otherwise 20 is really 2000 pips on EUR/USD.. and order can not have SL and TP over 1000 pips... Post #3 Quote Jun 26, 2008 10:03pm Jun 26, 2008 10:03pm ravster | Joined Jun 2008 | Status: Member | 31 Posts Thanks Charlinks, Your suggestion worked, and I'm no longer getting the error 4107. Instead of using (SL * Point), I had to use (Ask - (SL * Point)). and it worked perfectly, otherwise it was giving an error 130. Thank you, Ravi Post #4 Quote Last Post: Jun 27, 2008 2:34am J
• All times are UTC Powered by phpBB Forum Software © phpBB Group
4062 | TOP | OrderModify error 1 >> 2012年12月16日 OrderSend error 4107 詳細のPrintとして下記が表示されます。invalid price 79.23982186 for OrderSend functionこれは、新規注文時の指値などの価格の小数点以下が多いことが原因です。Price = 79.23982186;NewPrice = NormalizeDouble(Price, Digits);NormalizeDoubleの関数を使用することで適正な小数点以下の数字に変換されることで問題を解消できます。タグ:mq4 コード エラー 【関連する記事】 OrderModify error 1 OrderSend error 4062 '}' - unbalanced parentheses posted by あお at 10:51| Comment(0) | メタトレーダーエラー | | この記事へのコメント コメントを書く お名前: メールアドレス: ホームページアドレス: コメント: 認証コード: [必須入力] ※画像の中の文字を半角で入力してください。 ■最もオススメする教材 ⇒プログラミングする時に必ず手元に置いておく本はコチラ 最近の記事 (12/16)OrderModify error 1 (12/16)OrderSend error 4107 (12/16)OrderSend error 4062 (12/16)'}' - unbalanced parentheses (12/08)メタトレーダーはスプレッドが広いのか? カテゴリ 日記(0) 検証(1) メタトレーダー(1) メタトレーダーエラー(4) 過去ログ 2012年12月(6) タグクラウド mq4 MT4 エラー コード スプレッド RDF Site Summary RSS 2.0 Seesaaブログ Copyright © メタトレーダーのエラー対策とリアル運用 All Rights Reserved. × この広告は1年以上新しい記事の投稿がないブログに表示されております。