Store CTime object in registry

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.

Right, both answers were perfectly acceptable so I split the 200 points between you both. AlexFM I have given you another 250 points as you effectively answered another of my questions - http:Q_20963387.html - although you did so at http:Q_20963870.html - and never accepted credit for it.

Thanks all.

0

Featured Post

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

This is to be the first in a series of articles demonstrating the development of a complete windows based application using the MFC classes. I’ll try to keep each article focused on one (or a couple) of the tasks that one may meet.
Introductio…

Introduction:
Dialogs (1) modal - maintaining the database.
Continuing from the ninth article about sudoku.
You might have heard of modal and modeless dialogs. Here with this Sudoku application will we use one of each type: a modal dialog …

Internet Business Fax to Email Made Easy -
With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number.
You'll receive secure faxes in your email, fr…