Click here to Skip to main content
15,896,387 members
Home / Discussions / C#
   

C#

 
GeneralRe: C# and file access permission failures on Windows 2000 Pin
Parrish18-May-04 4:17
Parrish18-May-04 4:17 
GeneralPocket PC 2002 and C# Pin
RobMenegon18-May-04 1:44
professionalRobMenegon18-May-04 1:44 
GeneralRe: Pocket PC 2002 and C# Pin
Heath Stewart18-May-04 4:02
protectorHeath Stewart18-May-04 4:02 
GeneralRe: Pocket PC 2002 and C# Pin
RobMenegon18-May-04 11:46
professionalRobMenegon18-May-04 11:46 
GeneralRe: Pocket PC 2002 and C# Pin
Heath Stewart19-May-04 3:31
protectorHeath Stewart19-May-04 3:31 
GeneralRe: Pocket PC 2002 and C# Pin
RobMenegon19-May-04 11:15
professionalRobMenegon19-May-04 11:15 
GeneralQuestion regarding the purpose of the global system hook Pin
Adam Goossens18-May-04 1:29
Adam Goossens18-May-04 1:29 
GeneralRe: Question regarding the purpose of the global system hook Pin
Dave Kreskowiak18-May-04 2:48
mveDave Kreskowiak18-May-04 2:48 
Adam Goossens wrote:
Surely it would be better to intercept it at a choke point rather than cater for every possible location? And if that was the case, surely it would also mean you wouldn't unnecessarily slow down the other processes on the system?

That's the pitfall for using a global hook. If you monitor the system for a specific message to a specific window, a global hook is not an appropriate solution. Global hooks are more for, say, monitoring the the system for keyboard events, mouse events, ...

I've used it to disable the Window key on our keyboards since there are keyboard shortcuts to launch Explorer even though policy has launching Explorer prohibited. This was a low level keyboard hook that intercepted keyboard messages before they were dispatched to the system.

If written properly and by that, I mean very efficiently, you'd never know the hook was there. Improperly written hooks, on the other hand, can seriously degrade performance. The keyboard hook I wrote just examined the keys coming from the keyboard driver and didn't pass along the key combinations that we needed it to suppress. This hook never showed a single second of consumed CPU time during the entire time it has been running, so it works really fast.



RageInTheMachine9532
"...a pungent, gastly, stinky piece of cheese!" -- The Roaming Gnome

GeneralRe: Question regarding the purpose of the global system hook Pin
Joel Lucsy18-May-04 3:38
Joel Lucsy18-May-04 3:38 
GeneralRe: Question regarding the purpose of the global system hook Pin
Adam Goossens18-May-04 3:53
Adam Goossens18-May-04 3:53 
GeneralText editor using c# Pin
shajuMathew18-May-04 1:22
shajuMathew18-May-04 1:22 
GeneralRe: Text editor using c# Pin
Heath Stewart18-May-04 4:04
protectorHeath Stewart18-May-04 4:04 
GeneralRe: Text editor using c# Pin
leppie18-May-04 7:11
leppie18-May-04 7:11 
Questionhow to run the algorithm whose code is given in c# Pin
gcmishra18-May-04 1:08
gcmishra18-May-04 1:08 
AnswerRe: how to run the algorithm whose code is given in c# Pin
Colin Angus Mackay18-May-04 1:17
Colin Angus Mackay18-May-04 1:17 
GeneralAdding and Retriving Values From Registry Pin
Anonymous18-May-04 1:07
Anonymous18-May-04 1:07 
GeneralRe: Adding and Retriving Values From Registry Pin
Aryadip18-May-04 1:22
Aryadip18-May-04 1:22 
GeneralRe: Adding and Retriving Values From Registry Pin
johnny.vilhjalmsson18-May-04 2:32
johnny.vilhjalmsson18-May-04 2:32 
GeneralCustom project and custom code pages Pin
narada10818-May-04 1:07
narada10818-May-04 1:07 
GeneralRe: Custom project and custom code pages Pin
Dave Kreskowiak18-May-04 2:34
mveDave Kreskowiak18-May-04 2:34 
GeneralRe: Custom project and custom code pages Pin
Heath Stewart18-May-04 4:11
protectorHeath Stewart18-May-04 4:11 
GeneralRe: Custom project and custom code pages Pin
narada10818-May-04 5:40
narada10818-May-04 5:40 
GeneralRe: Custom project and custom code pages Pin
Heath Stewart18-May-04 5:46
protectorHeath Stewart18-May-04 5:46 
GeneralRe: Custom project and custom code pages Pin
narada10818-May-04 6:14
narada10818-May-04 6:14 
GeneralRe: Custom project and custom code pages Pin
Heath Stewart18-May-04 6:22
protectorHeath Stewart18-May-04 6:22 

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.