简体   繁体   中英

Pressing a key in c#

I'm developing a program that searches for a running program and press a button on it automatically But How can I press the enter key on the keyboard from my code (send the command of the enter key)? Thanks.

You can use SendKeys .

Please check this CodeProject tutorial for detailed How To.

替代文字

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM