Store CTime object in registry
Posted on 2004-05-02
I am writing an app that uses "Reminders"; i.e. the user can enter a subject, details and due time as a reminder for them to do something. The subject and details of the reminder are stored in CStrings (obtained from CEdit controls) and the data/time are stored in CTime objects (obtained from CDateTimeCtrl controls). When that time arrives, a dialogue box pops up telling the user so. In essence, it is very similar to Outlook's "tasks".
All of this information is to be stored in the registry, but I cannot see how to store a CTime object in a manner so it can re-read back. I need to read it back to re-initialise the CDateTimeCtrl controls when re-displaying all of the reminders the next time the app is started and the user chooses to view them.
Any ideas ?