|
-
Aug 17th, 2001, 03:35 AM
#1
Lock of The Desktop
Dear ALL,
I'm trying to lock the Desktop from being accessed by the user unless he enter the correct Username and passswod ....
i managed to lock the desktop from being accessed by mouse ...
but the problem is that he still can use the sys. keys (as CTRL , ALT + TAB , Windows key....etc) in which i want to disable .. so only he can type letters and numbers ..... any suggestion will make me very greatful...
Thanx in advance
-
Aug 17th, 2001, 04:52 AM
#2
See my post here for info on blocking sys keys for the Windows 9x platform.
(Code does not work for Windows NT/2000)
HTH.
-
Aug 17th, 2001, 10:20 AM
#3
Thanks..BUT the ALT+F4 is still working .
Thanks alot for ur concern and time....
everything is Ok except that the ALT+F4 combination is still working and it as usual cuase the applicaiton to terminate ...in which i don't wan't the user to be able to do...
any Help...
Thanks in advace
-
Aug 17th, 2001, 10:33 AM
#4
Frenzied Member
You can do that by putting this code in form_Unload:
VB Code:
If PasswordC = False Then Cancel = True
And put this code just before the form UNLOADS because of a correct password:
Don't forget to put this in the General_Declarations:
VB Code:
Public PasswordC As Boolean
MicroBasic
Dragon Shadow Trainer
There is no good or evil in the world...only programmers and fools .
-
Aug 17th, 2001, 10:36 AM
#5
Frenzied Member
Or, put this in the FORM_QUERYUNLOAD Section:
VB Code:
If unloadmode <> 1 Then Cancel = True
MicroBasic
Dragon Shadow Trainer
There is no good or evil in the world...only programmers and fools .
-
Aug 17th, 2001, 02:41 PM
#6
But this Way????
Thanx Microbasic for ur time...
But this way he Might Press (ALT+F4) and close the App
witout entering the correct things... and i want to prevent him from doing this
-
Aug 17th, 2001, 02:42 PM
#7
Member
In the Form_QueryUnload event, add the line Cancel = True after checking to make sure that the event was called from something OTHER than code (see the VB help for QueryUnload).
-
Aug 17th, 2001, 02:46 PM
#8
-
Aug 18th, 2001, 03:16 PM
#9
thanx alot... yes u where wright ... thanx again....
ooh ... sorry if i would be rood... do u know about Viedo Streaming an VB .... forgive me....
-
Aug 18th, 2001, 10:16 PM
#10
Registered User
The idea is to hide all the windows and display your app in maximized form.
Then even if they use ctl+alt+del they still can't get to anything. To disable ctl+alt+del in NT need to subclass it. Alternatively dirty way is to capture keypresses from a timer.
-
Aug 19th, 2001, 03:01 AM
#11
need more help
can u plz be more descriptive about the subclass tech. u just declared about...
-
Aug 19th, 2001, 03:50 AM
#12
Registered User
Well I don't think it is possible from VB, you need C++ to create a standard dll to create a system wide hook.
Last edited by Nucleus; Aug 19th, 2001 at 04:22 AM.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|