2015.03.26 11:44:13.934 test (MIX-6.15,H1) Bingo! We done. 2015.03.26 11:44:13.934 test (MIX-6.15,H1) Init OK.
alle verfügbaren Instrumente werden in die Marktübersicht aufgenommen.
Habe den Test überarbeitet. Habe genau auf MIX mit allen anderen Instrumenten geworfen.
Alles in Ordnung.
Das Konto ist real in Otkritie. Die Karten Ri und Si sind ebenfalls offen.
2015.03.26 13:56:01.024 Test (MIX-6.15,M1) Init OK.
Real Opening win7 x64 C:\Programme\Open Broker\terminal64.exe build 1085
Ich danke Ihnen!
Ich habe:
Win7/64 Ultimate MT5 build 1085
2015.03.26 15:30:37.229 Test (MIX-6.15,M1) Sorry! Get Bars failed. 2015.03.26 15:30:37.229 Test (MIX-6.15,M1) Get Bars failed RTS-6.15 Last error = 4401
Ich habe MIX-6.15 fallen, WIN 7-64 home premium MT5 build 1085:
2015.03.26 15:44:27.729 Test (MIX-6.15,H1) Get Bars failed MIX-6.15 Last error = 4401 2015.03.26 15:44:27.729 Test (MIX-6.15,H1) Sorry! Get Bars failed.
FORTS Benutzer!
Bitte nehmen Sie sich 3 Min. Zeit!
Um den "Floating"-Fehler zu beheben, benötigen Sie
MEHR Statistik!
FORTS Benutzer!
Bitte nehmen Sie sich 3 Min. Zeit!
Um den "Floating"-Fehler zu beheben, benötigen Sie
MEHR Statistik!
Ausgaben 3 min))
Michael, das geht nicht - mit einer einzigen Anfrage in der Inite. Es gibt keine Garantie, dass alle Daten fertig sind.
So macht man es - natürlich mit Verstand.
#property copyright "Copyright 2014, MetaQuotes Software Corp." #property link "http://www.mql5.com" #property version "1.00" #property indicator_separate_window #property indicator_buffers 1 #property indicator_plots 1 // bool is_failed = false; //+------------------------------------------------------------------+ //| Custom indicator initialization function | //+------------------------------------------------------------------+ int OnInit() { //--- indicator buffers mapping SymbolSelect( "MIX-6.15", true ); SymbolSelect( "RTS-6.15", true ); SymbolSelect( "Si-6.15", true ); //--- ResetLastError(); //--- int total_bars = Bars( "MIX-6.15", PERIOD_M1 ); if ( total_bars > 0 ) { total_bars = Bars( "RTS-6.15", PERIOD_M1 ); if ( total_bars > 0 ) { total_bars = Bars( "Si-6.15", PERIOD_M1 ); { if ( total_bars > 0 ) { Print( "Init OK." ); } else { is_failed = true; Print( "Get Bars failed Si-6.15 Last error = ", string(GetLastError() ) ); } } } else { is_failed = true; Print( "Get Bars failed RTS-6.15 Last error = ", string(GetLastError() ) ); } } else { is_failed = true; Print( "Get Bars failed MIX-6.15 Last error = ", string(GetLastError() ) ); } //--- return(INIT_SUCCEEDED); } //+------------------------------------------------------------------+ //| Custom indicator iteration function | //+------------------------------------------------------------------+ int OnCalculate(const int rates_total, const int prev_calculated, const datetime &time[], const double &open[], const double &high[], const double &low[], const double &close[], const long &tick_volume[], const long &volume[], const int &spread[]) { ResetLastError(); //--- int total_bars = Bars( "MIX-6.15", PERIOD_M1 ); if ( total_bars > 0 ) { total_bars = Bars( "RTS-6.15", PERIOD_M1 ); if ( total_bars > 0 ) { total_bars = Bars( "Si-6.15", PERIOD_M1 ); { if ( total_bars > 0 ) { Print( "Init OK." ); } else { is_failed = true; Print( "Get Bars failed Si-6.15 Last error = ", string(GetLastError() ) ); } } } else { is_failed = true; Print( "Get Bars failed RTS-6.15 Last error = ", string(GetLastError() ) ); } } else { is_failed = true; Print( "Get Bars failed MIX-6.15 Last error = ", string(GetLastError() ) ); } //--- if ( is_failed ) { Print( "Sorry! Get Bars failed." ); } else Print( "Bingo! We done."); //--- return value of prev_calculated for next call return(rates_total); }
Ein Mehrwährungsindikator ist nicht so einfach.
Prüfen Sie zunächst die Verfügbarkeit der Instrumente:
bool CorrectSymbol( string symbol ) { ResetLastError(); if ( SymbolInfoDouble( symbol, SYMBOL_BID ) > DBL_EPSILON ) return(true); // символ не выбран в "Обзоре рынка" (нет в списке доступных) if ( GetLastError() == 4302 ) { if ( SymbolSelect( symbol, true ) && SymbolInfoInteger( symbol, SYMBOL_SELECT ) ) return(true); } return(false); }
Öffnen Sie dann die Charts aller verwendeten Instrumente (ein unsichtbares Chart-Objekt reicht aus), damit die Historie normal geladen wird.
Und erst dann versuchen, den Verlauf mit CheckLoadHistory zu laden.
Aber auch das reicht möglicherweise nicht aus.
Ausgabe von 3 Minuten))
Michael, das ist nicht möglich - mit einer einmaligen Anfrage bei der Inite. Es gibt keine Garantie dafür, dass alle Daten bereits fertig sind.
So macht man es - natürlich mit Verstand.
Ich stimme zu, es ist ein bisschen falsch, ich habe den Code umgeschrieben (siehe den Quellcode), ABER das Ergebnis ist das gleiche!
2015.03.26 16:20:55.564 Test (MIX-6.15,M1) Sorry! Get Bars failed. 2015.03.26 16:20:55.564 Test (MIX-6.15,M1) Get Bars failed Si-6.15 Last error = 4401
Einverstanden, ein bisschen falsch, schrieb den Code neu, ABER das Ergebnis ist das gleiche!

- Freie Handelsapplikationen
- Über 8.000 Signale zum Kopieren
- Wirtschaftsnachrichten für die Lage an den Finanzmärkte
Sie stimmen der Website-Richtlinie und den Nutzungsbedingungen zu.
Guten Tag!
Auch hier kann der Servodex den Fehler nicht reproduzieren!
Bitte kompilieren Sie diesen Code und "werfen" Sie den Indikator auf das MIX-6.15 Symbol
( nicht von MetaEditor )
Bitte veröffentlichen Sie die Ergebnisse (die auf der Registerkarte "Experten" angezeigt werden sollen) hier.