How to Change Date Time Properties
Keywords: date time
Question:
Do you have an example of how to change the date time properties?
Answer:
AddExtender("wwctl34I.dll")
; Setup date and time
RUN ("rundll32.exe","shell32.dll,Control_RunDLL timedate.cpl")
netwnd=DllHwnd("Date/Time Properties")
systabwnd=cWndByClass(netwnd,"SysTabControl32")
cSetTabItem(systabwnd,2)
srvhwnd=cWndByName(netwnd,"Time Zone")
lbWnd=cWndByID(srvhwnd, 101) ;READS COMBO-BOX CONTROL, THE IDENT=101
response=cGetCBText(lbWnd)
response=strreplace(response,@tab,@crlf)
Message("Response",response)
prefchkbox=cWndByname(srvhwnd,"Automatically adjust clock for daylight saving changes")
chk=cCheckbox(prefchkbox,-1)
if chk==1
Message("Use Preferred Devices is set to",chk)
else
cCheckbox(prefchkbox, 1)
endif
Article ID: W13860
Filename: Change Date Time Properties.txt