【发布时间】:2014-01-28 06:50:45
【问题描述】:
我正在编写一个脚本,需要从对话框中的条目中复制和粘贴文本
set query to text returned of (display dialog "Enter Text" default answer "" buttons {"Input", "Cancel"} default button 1)
query
tell application "System Events"
keystroke "c" using command down
keystroke "v" using command down
end tell
当我运行此脚本时,它会复制并粘贴“将查询设置为文本...”
如何复制我输入的查询?我稍后将把文本粘贴到其他地方,但我需要弄清楚如何实际复制文本。我正在使用击键查询,但是当字符串很长时会花费很长时间
【问题讨论】:
标签: copy applescript paste dialog