Solved

DateTime control in MFC which takes upto milliseconds

Posted on 2004-09-14
3
1,184 Views
Last Modified: 2013-11-20
Hi,

I want to a MFC date time control which can take milliseconds, seconds, minutes & hrs into consideration. I am aware of only CDateTimeCtrl in vc++, but this cannot take milliseconds. I also need to extract time from such a control and do <,>,== comparisions. Can anyone please help me?

Thanks
Madhavi
0
Comment
Question by:j_madhavi
3 Comments
 
LVL 44

Accepted Solution

by:
AndyAinscow earned 30 total points
ID: 12062311
You need to code your own control (or have a separate edit box for the millisecond).

Have a look at SYSTEMTIME for storing/manipulating the times.
Members
wYear
Specifies the current year. The year must be greater than 1601.
Windows XP: The year cannot be greater than 30827.

wMonth
Specifies the current month; January = 1, February = 2, and so on.
wDayOfWeek
Specifies the current day of the week; Sunday = 0, Monday = 1, and so on.
wDay
Specifies the current day of the month.
wHour
Specifies the current hour.
wMinute
Specifies the current minute.
wSecond
Specifies the current second.
wMilliseconds
Specifies the current millisecond.
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Rewrite URL With Encoded Characters 6 78
Error on moodle after upgrade 3 130
List out all word 7 291
MaxSpan challenge 9 96
Introduction: Hints for the grid button.  Nested classes, templated collections.  Squash that darned bug! Continuing from the sixth article about sudoku.   Open the project in visual studio. First we will finish with the SUD_SETVALUE messa…
If you use Adobe Reader X it is possible you can't open OLE PDF documents in the standard. The reason is the 'save box mode' in adobe reader X. Many people think the protected Mode of adobe reader x is only to stop the write access. But this fe…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question