Dear MQL5 Community,
I am simply trying to get the handle of a custom indicator (donchian channel) but It simply won't work even after hours of trying different approaches and searching the Forum. It would be great if someone can help me! :)
Here is the base case:
- indicator successfully compiled and placed into folder MQL5\\Indicators
- the donchian channel indicator I choosed (https://www.mql5.com/de/code/1601) has only one input which is the "InpChannelPeriod"
- when I run the code below, I get the "-1" for the handle and as error code the 4802
Here is the simple code:
I would be so thankful if someone has an idea!
Alex
- Wir können hier deutsch sprechen :)
- Überprüf die Schreibweise des Indikators und, dass er an der an der richtigen Stelle liegt in ..\MQL\Indicators\..
1. Wunderbar, vielen Dank lieber Carl.
2. Der Indikator "donchian_channel" liegt direkt als .ex5 und mq5 in dem Ordner: "...Terminal/D0E820.../MQL5/Indicators" (in keinem Subfolder).
Ich hatte sogar Metatrader 5 neu installiert. Das hat leider auch nicht geholfen.
Hast du oder jemand anderes vielleicht noch eine Idee? Kann das Problem evtl. auf einer höheren Ebene (System) liegen?
Ganz lieben Dank!
Als Nachtrag:
wenn ich in der iCustom Funktion als Ordner statt "donchian_channel" -> "Examples\\donchian_channel" übergebe (was keinen Sinn macht, weil der Indikator da nicht liegt) bekomme ich unterschiedliche Error Codes:
für "donchian_channel" (als Ordner Param im iCustom): Handle: -1 Error:0 (hier liegt der Indikator)
für "Examples\\donchian_channel" (als Ordner Param im iCustom): Handle: -1 Error 4802 (hier liegt der Indikator nicht)
Das habe ich versucht, leider ohne Erfolg :(.
Ich habe mal ein Screenshot angehangen, damit man sieht, wo sich der Indikator in der Ordnerstruktur befindet (.ex5 natürlich auch vorhanden) mitsamt dem simplen Code. Ich habe das Gefühl es ist ein einfacher, dummer Fehler.
Ganz lieben Dank!
Steht doch da, was nicht ok ist:
"Expresion not boolean" und die Zeile auch:
if (dchandle=INVALID_HANDLE)
Es müssen zwei = sein:
if (dchandle==INVALID_HANDLE)
Carl, vielen Dank, du hast natürlich vollkommen Recht. Jetzt klappt es!
Danke, für Deine Mühe und Zeit! :) Vielleicht macht jemand anderes den gleichen Fehler und wird dann Hilfe durch diesen Thread finden.
- 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.
Dear MQL5 Community,
I am simply trying to get the handle of a custom indicator (donchian channel) but It simply won't work even after hours of trying different approaches and searching the Forum. It would be great if someone can help me! :)
Here is the base case:
- indicator successfully compiled and placed into folder MQL5\\Indicators
- the donchian channel indicator I choosed (https://www.mql5.com/de/code/1601) has only one input which is the "InpChannelPeriod"
- when I run the code below, I get the "-1" for the handle and as error code the 4802
Here is the simple code:
I would be so thankful if someone has an idea!
Alex