Click to See Complete Forum and Search --> : calling timedate.cpl
Brandon
Nov 17th, 1999, 06:04 AM
I need to pull up windows time and date program in my vb application to allow users to set system time and date. How do I run this prog. I also need it to run under windows and NT.(differnt paths).
Thanks
Brandon
Compwiz
Nov 17th, 1999, 06:14 AM
To retrieve the time and date: use the following:
lblTime.Caption = Time
lblDate.Caption = Date
To set,
Time = {The Time Goes Here}
Date = {The Date Goes Here}
-------- Simple --------
------------------
Tom Young, 14 Year Old
tyoung@stny.rr.com
ICQ: 15743470 (http://wwp.icq.com/15743470) Add Me (http://wwp.icq.com/scripts/search.dll?to=15743470) ICQ Me (http://wwp.icq.com/scripts/contact.dll?msgto=15743470)
AIM: TomY10 (http://www.aol.com/aim/aim30.html)
PERL, JavaScript and VB Programmer
Brandon
Nov 17th, 1999, 06:18 AM
Thanks for the reply.
I am already able to pull the date and time into my app ok. What I need to do it CHANGE the system date and time.
Ice
Nov 17th, 1999, 10:41 AM
this will do what you want, just replace the modem.cpl with desired .cpl
'Launch Windows Modem Properties Dialog
Dim dblReturn As Double
dblReturn = Shell("rundll32.exe shell32.dll,Control_RunDLL modem.cpl", 5)
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.