Support Board
Date/Time: Sun, 22 Dec 2024 16:50:07 +0000
Post From: [Documentation Suggestion]
[2015-02-08 01:35:53] |
Kiwi - Posts: 375 |
The new persistent variables look great. It took me a couple of rereads to be sure they weren't going to mess up all of my existing code so I wondered if an example in the documentation showing the transition from old to new would help others. Something like: OLD DECLARATION AND USAGE int& dumdum = sc.PersistVars->i1; int& timeForLoop = sc.PersistVars->i14; double& msg3 = sc.PersistVars->d23; float& debugReport = sc.PersistVars->f16; dumdum = 999; timeForLoop = sc.CurrentSystemDateTime.GetTime(); msg3 = 55.024; debugReport = 6.3; NEW DECLARATION AND USAGE - showing conversion with minimum change int& dumdum = sc.GetPersistentInt(1); int& timeForLoop = sc.GetPersistentSCDateTime(14); double& msg3 = sc.GetPersistentDouble(23); float& debugReport = sc.GetPersistentFloat(16); dumdum = 999; timeForLoop = sc.CurrentSystemDateTime.GetTime(); msg3 = 55.024; debugReport = 6.3; |