One way: Use the NTP conversion commands, convert the Opto date/time table to a NTP timestamp (64 bit) add/subtract 7 days (7 * 24 * 60 * 60 * 0x100000000i64) to the NTP timestamp and then convert back.
Thanks for the code Philip. Just to complicate things, If I wanted to move forward and back a week at a time, always starting on a Monday, what would I need to to do? Is it as simple as adding or subtracting 7 somewhere?
Thanks Philip. Does this incorporate the previous code for keeping things on Mondays? It looks like it does but I want to make sure before Incorporate into my strategy.
Sure does. If you set bInitGroovDateTime to initialize to 1 on strategy run, then ntGroovDateTime will be set to this weeks Monday. Modify as you see fit.