Any advice would be greatly appreciated!
Something seems wrong in your code. Please show the part of your code where:
- You are declaring the indicator as a resource.
- You are calling the iCustom() function for it.
Also, re-read the documentation about including an indicator as a resource ... Documentation on MQL5: MQL5 programs / Resources
Working with custom indicators included as resources
One or several custom indicators may be necessary for the operation of MQL5 applications. All of them can be included into the code of an executable MQL5 program. Inclusion of indicators as resources simplifies the distribution of applications.
Below is an example of including and using SampleIndicator.ex5 custom indicator located in terminal_data_folder\MQL5\Indicators\ directory:
//+------------------------------------------------------------------+ //| SampleEA.mq5 | //| Copyright 2013, MetaQuotes Software Corp. | //| https://www.mql5.com | //+------------------------------------------------------------------+ #resource "\\Indicators\\SampleIndicator.ex5" int handle_ind; //+------------------------------------------------------------------+ //| Expert initialization function | //+------------------------------------------------------------------+ int OnInit() { //--- handle_ind=iCustom(_Symbol,_Period,"::Indicators\\SampleIndicator.ex5"); if(handle_ind==INVALID_HANDLE) { Print("Expert: iCustom call: Error code=",GetLastError()); return(INIT_FAILED); } //--- ... return(INIT_SUCCEEDED); }

- www.mql5.com
Please consider which section is most appropriate — https://www.mql5.com/en/forum/172166/page6#comment_49114893
Any advice would be greatly appreciated!
From this article:
The checks a trading robot must pass before publication in the Market
If the operation of your program requires calling to the data of a custom indicator, then all the necessary indicators should be placed to the Resources. Market products are supposed to be ready to work in any unprepared environment, so they should contain all everything they need within their EX4/EX5 files. Recommended related articles:
--------------------
And it may be some other errors in your code, so read more information:
Solving Automatic Validation Problems Arising During Product Submission in MQL5 Market - the blog post
Something seems wrong in your code. Please show the part of your code where:
- You are declaring the indicator as a resource.
- You are calling the iCustom() function for it.
Also, re-read the documentation about including an indicator as a resource ... Documentation on MQL5: MQL5 programs / Resources
Thank you, Fernando, for your response.
Yes, I’ve read the documentation and tried various suggestions I found in the forum. My issue is solely with the MQL5 checker.
I was wondering if there might be a way to pass the check or perhaps include the indicator in the product description as a workaround.
#resource "\\Indicators\\Dynamic fibos.ex5" int Fb_handle; int OnInit () : : //initialize crossed for (i = 0; i < ArraySize(crossed); i++) crossed[i] = true; Fb_handle = iCustom(NULL, PERIOD_CURRENT, "Dynamic fibos", true, Fibo_Level_1, Fibo_Level_2, Fibo_Level_3, Fibo_Level_4, Fibo_Level_5, 0.886, 0, Bars_Back, false); if(Fb_handle < 0) { Print("The creation of fibos has failed: Dynamic Fb_handle=", INVALID_HANDLE); Print("Runtime error = ", GetLastError()); return(INIT_FAILED); } return(INIT_SUCCEEDED); }
You may have read the documentation but you are not following it's instructions correctly.
Your code is incorrect ...
Fb_handle = iCustom(NULL, PERIOD_CURRENT, "Dynamic fibos", true, Fibo_Level_1, Fibo_Level_2, Fibo_Level_3, Fibo_Level_4, Fibo_Level_5, 0.886, 0, Bars_Back, false);
This is how you should be using the indicator name parameter ...
Fb_handle = iCustom(NULL, PERIOD_CURRENT, "::Indicators\\Dynamic fibos", true, Fibo_Level_1, Fibo_Level_2, Fibo_Level_3, Fibo_Level_4, Fibo_Level_5, 0.886, 0, Bars_Back, false);

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Any advice would be greatly appreciated!