A
Art
hi everyone,
maybe someone can give me advice how to implement a .net - class that
receives (keystroke) messages. i dove already into the topic of
Application / AplicationContext and IMessageFilter. I understood, that
i can attach a message loop to a thread, and this thread then raises
the events in forms, in case windows sends a message to that form. but
it is always just a Form that gets messages routed to. in my case i
don't want a form.
in this simple example it should just be a class that listens to
keystrokes (without the console) and raise a keystroke-event or
however else it handles the message subsequently.
I spent the whole night on that topic and read several times, that
such a thing can not be achieved with .net/c#. WinAPI-funtions have to
be used to do that.
If so (or not) can anyone point me into the right direction? I have
some understanding of .net/c# but none at all with unmanaged code or
dll-imports. so if you provide advice can you please also post a
simple code sample of a .net class that can process messages.
thanks in advance,
Art
maybe someone can give me advice how to implement a .net - class that
receives (keystroke) messages. i dove already into the topic of
Application / AplicationContext and IMessageFilter. I understood, that
i can attach a message loop to a thread, and this thread then raises
the events in forms, in case windows sends a message to that form. but
it is always just a Form that gets messages routed to. in my case i
don't want a form.
in this simple example it should just be a class that listens to
keystrokes (without the console) and raise a keystroke-event or
however else it handles the message subsequently.
I spent the whole night on that topic and read several times, that
such a thing can not be achieved with .net/c#. WinAPI-funtions have to
be used to do that.
If so (or not) can anyone point me into the right direction? I have
some understanding of .net/c# but none at all with unmanaged code or
dll-imports. so if you provide advice can you please also post a
simple code sample of a .net class that can process messages.
thanks in advance,
Art