Archived

This topic is now archived and is closed to further replies.

Date Format & Win98

This topic is 5019 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, I have been developing a program that is very date dependent using c++ and win32. I use the Date Time Picker, under ME and XP, the date time picker returns a date in the format of 18/03/2004, i have based my code around this format, unfortunatly... The planned user of this program uses Win98 and under win98 the date time picker returns 18/03/04. I refuse to believe win98 suffers from the millenium bug, so if anyone can point me in the right direction of how to force the date time picker to return the full year, that would be much appriciated, thanks.

Share this post


Link to post
Share on other sites
CDateTimeCtrl control creates itself with a format that matches the locale setting in Control Panel. You can force a particular format with a call to SetFormat. This call forces the format dd-MMM-yy, which shows 03-APR-98 for April 3rd, 1998.

pCtrl->SetFormat(_T("dd-MMM-yy"));









Share this post


Link to post
Share on other sites