Click here to Skip to main content
15,907,687 members
Home / Discussions / C#
   

C#

 
QuestionProcessing global mouse and keyboard hooks in a secondary thread! Pin
AngryC19-Oct-06 21:07
AngryC19-Oct-06 21:07 
Hello,

I've read the following article:

http://www.codeproject.com/csharp/globalhook.asp

The code is working very well except for the problem the author mentioned:

Question:
I have a long delay when closing applications using hooks by clicking the x button in the titlebar. If I close the application via another event (button click) for example, that works fine.

Answer:
It's a know bug of Microsoft. It has to do with the Windows themes. If you disable the Windows themes, the problem goes away. Another choice is to have the hook code run in a secondary thread.

Can anyone tell me how can I 'have the hook code run in a secondary thread'?

I would really appreciate your help. Thanks.
QuestionUsing IR Port Pin
Ravikumar Patra19-Oct-06 19:21
professionalRavikumar Patra19-Oct-06 19:21 
AnswerRe: Using IR Port Pin
Ashish Derhgawen19-Oct-06 23:23
Ashish Derhgawen19-Oct-06 23:23 
GeneralRe: Using IR Port [modified] Pin
Ravikumar Patra29-Oct-06 17:42
professionalRavikumar Patra29-Oct-06 17:42 
QuestionCommunication internet Pin
nmhai8319-Oct-06 18:54
nmhai8319-Oct-06 18:54 
AnswerRe: Communication internet Pin
seee sharp19-Oct-06 21:40
seee sharp19-Oct-06 21:40 
Questionhow do i convert string to type? help please! Pin
abstar19-Oct-06 17:58
abstar19-Oct-06 17:58 
AnswerRe: how do i convert string to type? help please! Pin
Captain See Sharp19-Oct-06 18:25
Captain See Sharp19-Oct-06 18:25 
GeneralRe: how do i convert string to type? help please! Pin
abstar19-Oct-06 18:43
abstar19-Oct-06 18:43 
GeneralRe: how do i convert string to type? help please! [modified] Pin
Captain See Sharp19-Oct-06 19:30
Captain See Sharp19-Oct-06 19:30 
GeneralRe: how do i convert string to type? help please! Pin
J4amieC19-Oct-06 21:59
J4amieC19-Oct-06 21:59 
GeneralRe: how do i convert string to type? help please! Pin
Captain See Sharp20-Oct-06 13:49
Captain See Sharp20-Oct-06 13:49 
GeneralRe: how do i convert string to type? help please! Pin
abstar28-Oct-06 18:05
abstar28-Oct-06 18:05 
GeneralRe: how do i convert string to type? help please! Pin
J4amieC29-Oct-06 5:54
J4amieC29-Oct-06 5:54 
QuestionWhat is MyProjectName.vshost.exe.config ? Pin
Nadia Monalisa19-Oct-06 13:36
Nadia Monalisa19-Oct-06 13:36 
AnswerRe: What is MyProjectName.vshost.exe.config ? Pin
Ed.Poore19-Oct-06 13:42
Ed.Poore19-Oct-06 13:42 
GeneralRe: What is MyProjectName.vshost.exe.config ? Pin
Nadia Monalisa19-Oct-06 14:20
Nadia Monalisa19-Oct-06 14:20 
AnswerRe: What is MyProjectName.vshost.exe.config ? Pin
Anthony Mushrow19-Oct-06 13:42
professionalAnthony Mushrow19-Oct-06 13:42 
GeneralRe: What is MyProjectName.vshost.exe.config ? Pin
Nadia Monalisa19-Oct-06 14:20
Nadia Monalisa19-Oct-06 14:20 
Questionhow to send email with .net2003 [modified] Pin
Ah_Mohsen_aly19-Oct-06 12:20
Ah_Mohsen_aly19-Oct-06 12:20 
AnswerRe: how to send email with .net2003 Pin
Christian Graus19-Oct-06 13:24
protectorChristian Graus19-Oct-06 13:24 
QuestionC# & mswinsock.ocx Pin
Shahin7719-Oct-06 11:52
Shahin7719-Oct-06 11:52 
AnswerRe: C# & mswinsock.ocx Pin
Ed.Poore19-Oct-06 13:44
Ed.Poore19-Oct-06 13:44 
GeneralRe: C# & mswinsock.ocx Pin
Shahin7720-Oct-06 4:29
Shahin7720-Oct-06 4:29 
GeneralRe: C# & mswinsock.ocx Pin
Ed.Poore21-Oct-06 8:00
Ed.Poore21-Oct-06 8:00 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.