Results 1 to 2 of 2

Thread: How To Make Program Show After 15 mins

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Nov 2006
    Posts
    131

    How To Make Program Show After 15 mins

    I have developed a sign in program for our business center machine. What I am trying to do is to have the program maximize after 15 mins from sign in. We have a 15 minute usage limit on the computer. I would like to actually have the program log the user off the computer so that they will have to log in every 15 mins.

    How can I do this?

  2. #2
    I'm about to be a PowerPoster! kleinma's Avatar
    Join Date
    Nov 2001
    Location
    NJ - USA (Near NYC)
    Posts
    23,373

    Re: How To Make Program Show After 15 mins

    This code will log a user off of Windows:

    Code:
        Declare Function ExitWindowsEx Lib "user32" (ByVal dwOptions As Int32, ByVal dwReserved As Int32) As Int32
    
        Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
            ExitWindowsEx(&H0 Or &H10, 0)
        End Sub
    You could use a timer and set the interval to 900,000 which is 15 minutes

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