<!-- Download Links -->
<!-- Article image -->
CClockST is a class derived from MFC
CClockST just subclasses the supplied
CStatic control in your dialog and implements a simple clock and date!
CClockST features are:
- An easy way to put a clock in you dialog/application
- It's free!
- Full source code included!
- Cost-less implementation in existing applications
How to integrate CClockST in your application
In your project include the following files:
Also include the following bitmap resources:
Use dialog editor to create a static text called, for example,
(no matter what
size you give it, it will be resized by
) and create a member variable for this static control:
Now attach the static control to
. For dialog-based applications, in your
Or in your
DDX_Control(pDX, IDC_CLOCKFRAME , m_Clock);
Now start the clock, passing the ID resources of the bitmaps to use:
m_Clock.Start(IDB_CLOCKST_PANE, IDB_CLOCKST_BIG, IDB_CLOCKST_SMALL);
Your clock is now active! The static control created with dialog editor has been resized to
match the same size of the clock. There is no way to stop the clock once started.
Starts (and displays) the clock loading all the necessary bitmaps
and creating the worker thread.
DWORD Start(int nPaneID, int nBigID, int nSmallID, BOOL bAlternateDateFormat = FALSE)
Returns the class version as a short value.
static short GetVersionI()
Returns the class version as a string value.
static LPCTSTR GetVersionC()
- v1.3 (10/July/2002)
Fixed a problem in the OnPaint method
- v1.2 (29/June/2002)
Modified the Start method parameter list
- v1.0 (15/June/1999)
THE SOFTWARE AND THE ACCOMPANYING FILES ARE DISTRIBUTED "AS IS" AND WITHOUT ANY WARRANTIES WHETHER EXPRESSED OR IMPLIED.
NO REPONSIBILITIES FOR POSSIBLE DAMAGES OR EVEN FUNCTIONALITY CAN BE TAKEN.
THE USER MUST ASSUME THE ENTIRE RISK OF USING THIS SOFTWARE.