?
Solved

Lock Keyb and Mouse

Posted on 1998-12-11
3
Medium Priority
?
150 Views
Last Modified: 2010-04-04
hi,
I need a procedure which locks the keyboard and mouse.
the second procedure must give it free then.

Regards
ItsMe
0
Comment
Question by:ItsMe
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 12

Accepted Solution

by:
rwilson032697 earned 30 total points
ID: 1350528
Write a windows hook which traps WH_MOUSE and WH_KEYBOARD messages and ignores them. You will need to place them in a DLL also with a flag you can set via a function to turn on the ignoring of the messages or not.

Cheers,

Raymond.
0
 

Author Comment

by:ItsMe
ID: 1350529
How do I write such  program ? I know nothing about writing dll's and hooks !
Regards
ItsMe
0
 
LVL 12

Expert Comment

by:rwilson032697
ID: 1350530
If you do a serach on Delphi Super Page (http://sunsite.icm.edu.pl/delphi/) with "hook" as the key you should find some samples.

Also, start reading the Delphi help about DLLs and the helkp for SetWindowsHook in the Win32 help (type SetWindowsHook in an edit window, put the cursor in it and press F1)
Cheers,

Raymond.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
Suggested Courses

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question