Its too late. Everybody has seen it now.
You can pass a pointer to the rates array to the dll so you have access to all prices in the chart and then re-implement MACD (and other indicators you need) in your DLL. You cannot directly call mql4 functions from your dll, unfortunately this is absolutely impossible. This is a fundamental shortcoming of the mql language, I am not aware of any existing hack that would solve this problem.
onewithzachy:
You may want to import .mqh
You may want to import .mqh
This answer is not related to the question that has been asked.
.mqh files cannot be imported, only included. These things are not related.
Include just includes other mql4 files at compile time, this is the only purpose of #include. Whether you have the #import in the main file or in some include file does not make any difference for the imported functions. Putting the #imports into an include files is only a convenient way to better organize your code and avoid code duplication.
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
Hi,
How would I move the following function to a DLL please?
if(iMACD(NULL,0,12,26,9,PRICE_CLOSE,MODE_MAIN,0)>iMACD(NULL,0,12,26,9,PRICE_CLOSE,MODE_SIGNAL,0)) trade=sell;
Thanks
-Maria