I am interested to write an indicator that track VIX futures. The problem is that the ticker name change every mont and every year. For example Jan 2023 = CBOE:XVF2023. Feb = CBOE:VXG2023, etc. Every month has 3 Peter indicator followed by year.
I found out that i must use "simple string" format known in compilation. OK so i thought to use if(year == 2023) and then write 12 request.security() lines. Then i found that i can't use request.security() inside if() statement. Later i found that i am limited to 40 request.security() in one script.
So my question is there any way to achieve my goal getting the correct future contract price under the limitation that the ticker name is changing all the time
Tried use none simple string - forbidden Tried using if() - forbidden