AutoHotKey:如何在代码中发送CTRL B以及括号中的其他文本

时间:2012-11-28 21:21:29

标签: automation autohotkey

这是我的自动键代码:

::\update client::
(
Hi team,

We are emailing to advise you an update on following job:
#CTRL-B Here
Here
•   Our Reference:
Your Reference:
#CTRL-B Here
)

我正在尝试用一段文字替换word update client。我想在子弹点之前和子弹点之后发送 Ctrl + B 键。我该怎么做?有人可以用语法帮助我吗?感谢

2 个答案:

答案 0 :(得分:1)

您需要分割文字。

::\update client::
SendInput
(
Hi team,

We are emailing to advise you an update on following job:
)
SendInput, ^b
SendInput
(
Here
•   Our Reference:
Your Reference:
)
SendInput, ^b
Return

答案 1 :(得分:1)

这是我使用新行字符的解决方案。

::test::
    SendInput Hi team,`n`nWe are emailing to advise you an update on following job:
    SendInput ^b
    SendInput Here`n•   Our Reference:`nYour Reference:
    SendInput ^b
    return