Tip: How to lock Windows 2000 or XP

Share your advanced PureBasic knowledge/code with the community.
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Tip: How to lock Windows 2000 or XP

Post by BackupUser »

Code updated for 5.20+

Restored from previous forum. Originally posted by PB.

Use this command:

Code: Select all

LockWorkStation_()
In Windows 2000 Server/AdvSrv/Data Center/Pro, you get the "Workstation
Locked" dialog

In Windows XP Pro you get the login screen (same as selecting "Switch User"
when you log off.

Thanks to Tim Akal for giving me this tip.