Support Board
Date/Time: Sun, 22 Dec 2024 13:12:34 +0000
Post From: How to reference Persistent Variables from a different chart.
[2015-04-21 05:46:08] |
CustomIndicators - Posts: 126 |
Now, just one last question should top it off. Your example has greatly helped in my understanding. You set the following in your example code. float & PersistentFloat = sc.GetPersistentFloat(1);
In my code right now, I have this:float& peakOne = sc.PersistVars->f1;
Does this mean that I should change my code to this?:float& peakOne = sc.GetPersistentFloat(1);
Or should I do something more like this?:float& peakOne = sc.PersistVars->f1;
And then from there, I can reference it from other charts?
peakOne = sc.GetPersistentFloat(1); |