Find Code:
All Words
Any of the Words
Exact Phrase
Home
:
Code
:
Forums
:
Submit
:
Mailing List
:
About
:
Contact
Code
All
VB.NET
ASP.NET
C#
VB Classic
ASP Classic
Snippets
Popular
Resources
Submit Code
Forums
Articles
Tips
Links
Books
Contest
Link to us
This snippet lets you lock the desktop from access...
Author:
R.Shrivaths
E-mail:
Click to e-mail author
Website:
http://shrivaths.virtualave.net
Submitted:
5/15/2001
Version:
VB6
Compatibility:
VB6
Category:
Windows API
Views:
11861
This snippet lets you lock the desktop from access (I mean no clicks are received by Windows!) in under 15 lines of code!
Declarations:
Private Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long Private Declare Function EnableWindow Lib "user32" (ByVal hwnd As Long, ByVal fEnable As Long) As Long
Code:
Function EnableDesktop(En As Boolean) Dim HDesk As Long HDesk = FindWindow("Progman", vbNullString) If HDesk <> 0 Then EnableWindow HDesk, En End If End Function
Home
|
Forums
|
Submit
|
Books
|
Mailing List
|
Advertising
|
About
|
Contact
© 2023 A1VBCode. All rights reserved.
Legal disclaimer & terms of use
Privacy statement