Hello,
I'm developing an application which relies heavily on global hooks and
apparently C# does not support this type of hooking. What I have in mind is
to make a dll (in Delphi) that handle all the hooking and call a user
defined c# function for further handling, is this possible, could I link the
dll function with the C# function without any complication?
I considered moving the whole project to Delphi, the Visual Sudio IDE was
the only thing keeping me from doing so. Should I use C# for this type of
project or should I consider other alternatives, as hooking in Delphi is
straightforward.
Thanks
Yehia A.Salam
Mattias Sjögren - 30 Sep 2007 16:59 GMT
>I'm developing an application which relies heavily on global hooks and
>apparently C# does not support this type of hooking. What I have in mind is
>to make a dll (in Delphi) that handle all the hooking and call a user
>defined c# function for further handling, is this possible, could I link the
>dll function with the C# function without any complication?
You have to keep in mind that the hook procedure will be loaded and
called in different threads and processes depending on where the event
occurs. So you can't make a simple call to the C# code, it will
require some kind of interprocess communication mechanism.
Mattias

Signature
Mattias Sjögren [C# MVP] mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.