I've been trying to convert my NT7 indicators to NT8 in recent months. And the most common error I'm getting is "Error on calling 'OnBarUpdate' and the reasons are as follows:-
1. Sequence has no elements.
2. You are accessing an index with a value that is invalid since it is out of range. I.E accessing a series [barsAgo] with a value of 5 when there are only 4 bars
These reasons or errors never occurred in NT7 but are only having them in NT8. I have a if(CurrentBar is < x) return, and it's a pretty generous x, yet I'm still seeing the error for reasons I can't fathom. Fortunately for my key indicator, NT support was able to help as they did the conversion as it was available in the NT7 library. I wouldn't even know where to begin where there were over a thousand lines of code.
Could someone please help with explaining why these issues are cropping up? There are no issues with any of the indicators and it continues printing as per normal. Just that when you're about to logoff for the day and you look at your Control Center and you see the Error line.
Regards
Kay Wai

Comment