PDA

Click to See Complete Forum and Search --> : rebooting windows


brjames
Jan 17th, 2000, 05:42 AM
I have created a password program for when windows starts up just practising my VB.
I was wondering how I would go about re-booting the machine if the user types in the wrong password more than say, 3 times?

Thanks

brjames

Jan 17th, 2000, 06:03 AM
I know there is an API to bring up the shutdown window....I think there is also one to reboot but I cant find it...must be on my other computer....ill try and get back to you

:)

Glenn Harwood

chrisjk
Jan 17th, 2000, 09:20 AM
Check out http://www.vbsquare.com/tips/tip179.html

Regards,

------------------
- Chris
chris.kilhams@btinternet.com
If it ain't broke - don't fix it :)

JeffSM
Jan 17th, 2000, 10:35 AM
This will reboot your computer:

Declare Function ExitWindowsEx Lib "user32" (ByVal uFlags As Long, ByVal dwReserved As Long) As Long


ExitWindowsEx 2, 1

'If you wish turn off
'ExitWindowsEx 1, 0

Jefferson
Jefferson