Curiouser and curiouser this gets...
Just as a recap; There are three sources of week numbering I'm working with:
T-Clock's Custom Format String, which has been correct throughout the testing.
MS Outlook's Calendar (Both 2007 & 2010), which has been wrong throughout the testing.
T-Clock's Pop-up Calendar, which was wrong ... But now displays correctly after setting wr975 regestry key: HKEY_CURRENT_USER\Control Panel\International\iFirstWeekOfYear to 1.
Can you post some code (or be quite specific about the Calendar control/class you're using)?-mwb1100
Well.. T-Clock is still being compiled as pure C code - (Stop Laughing...) - So the only code used to create the control is this:
case WM_INITDIALOG: // Display 1 Month, 3 Months, or Full Year Calendar
ivMonths = GetMyRegLongEx("Calendar", "ViewMonths", 1); // New Feature - Coming Soon!
if(GetMyRegLong("Calendar", "ShowWeekNums", FALSE)) {
dwCalStyle = WS_BORDER|WS_CHILD|WS_VISIBLE|MCS_NOTODAYCIRCLE|MCS_WEEKNUMBERS;
}else{
dwCalStyle = WS_BORDER|WS_CHILD|WS_VISIBLE|MCS_NOTODAYCIRCLE;
}
hCal = CreateWindowEx(0, MONTHCAL_CLASS, "", dwCalStyle, 0,0,0,0, hDlg, 0, 0, NULL);
The calendar control defaults to today's date, so there really isn't any provision for feeding it (anything) GetWeekOfYear() - Which I seem to recall using successfully elseware in the Custom Format String code.
The question at this point, is if I add an option to adjust wr975's iFirstWeekOfYear registry entry ... Will that create a potential problem for other applications running on the user's machine?? (e.g. Sure it's easy as hell to do,
but should it be done?)
Side Note:
Both the XP VPC and the Win7 Host machine started with a default value of 0 for iFirstWeekOfYear.
XP numbers the weeks correctly with either 1 or 0 as a value.
Win7 (both x86 & x64) required iFirstWeekOfYear to be set to 1.
*Shrug* ...7 is broken?