Daemon in C# to listen for keypress

2019-04-03 01:47发布

I'm looking to create a small C# application that will either run as a daemon or sit in the taskbar, and wait for a specific keypress. When the expected keypress is encountered, I'll perform some actions.

This is going to be used primarily for quick-posting of data to a web-service I'm writing. I've looked around the net for a while, but my search terms have been too vague, and I haven't come across any concrete examples or guides.

Thanks,

Mike Trpcic

1条回答
倾城 Initia
2楼-- · 2019-04-03 02:02

I came across this on CodeProject. It'll capture keystrokes while it's not focused. CodeProject: A Simple C# Global Low Level Keyboard Hook

查看更多
登录 后发表回答