如何自动按Alt + a键 [英] How to press Alt+a key autometically
本文介绍了如何自动按Alt + a键的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
大家好
在我的应用程序中,我正在使用vb.net代码修改app.config文件的一部分。
但是当该行正在执行它的弹出一个对话框,我在那里手动按Alt + A然后只有app.config文件中发生的更改。
任何人都可以告诉我如何自动触发该按键。
谢谢
Hi all
In my application i am modifying one part of app.config file using vb.net code.
but when the line is executing it's popping one dialog box, where i am mannually pressing Alt+A then only the changes happening in the app.config file.
Can anyone please tell me how to fire that keypress automatically.
Thank you
推荐答案
使用此SendKeys.SendWait(%{A})
或者这个
use thisSendKeys.SendWait("%{A}")
or this
Dim wsh, MyKey
wsh = CreateObject("Wscript.Shell")
wsh.SendKeys("%{A}")
这篇关于如何自动按Alt + a键的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文