I am getting the following error when I try and call CheckTrailingStopLong inside of TrailingMA and I cannot seem to figure out what the issue is. I feel like I am missing something basic.
Error:
Pertinent Code:
If you would like me to come back and edit this with more of my code for whatever reason let me know. I am using the built in PositionInfo and TrailingMA files
So check your parameters.
Try this :
trailingMA.CheckTrailingStopLong(&positionInfo, normalizedStopLossLevel, normalizedTakeProfitLevel);
In case it doesn't work, then you would need to post code that compiles to be able to check.
Hi Alan,
Thank you for the response. That does make it compile however I then get new errors:
invalid pointer access in 'TrailingMA.mqh' (127,88) OnTester critical error
I have been trying to figure out why that new error is occurring but I seem to be coming up empty. Is it sounds as if it is an issue in the TrailingMA file but I have made no changes in there and am using the base one provided so I am assuming the issue is actually in my file and not TrailingMA.
![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
I am getting the following error when I try and call CheckTrailingStopLong inside of TrailingMA and I cannot seem to figure out what the issue is. I feel like I am missing something basic.
Error:
Pertinent Code:
If you would like me to come back and edit this with more of my code for whatever reason let me know. I am using the built in PositionInfo and TrailingMA files