Results 1 to 4 of 4

Thread: calling timedate.cpl

  1. #1

    Thread Starter
    New Member
    Join Date
    Nov 1999
    Posts
    2

    Post

    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

  2. #2
    Hyperactive Member
    Join Date
    Jul 1999
    Location
    NY, USA
    Posts
    270

    Post

    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
    [email protected]
    ICQ: 15743470 Add Me ICQ Me
    AIM: TomY10
    PERL, JavaScript and VB Programmer

  3. #3

    Thread Starter
    New Member
    Join Date
    Nov 1999
    Posts
    2

    Post

    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.

  4. #4
    Junior Member
    Join Date
    Oct 1999
    Posts
    16

    Post

    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)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width