想要将文件名作为参数传递给applescript
我在applescript上挣扎。我什至无法编写一个简单的脚本,该脚本以文件名并在适当的应用程序中打开它。
我尝试了一下:
on run argv
tell application "MindNode"
open file (item 1 of argv)
end tell
end run
这给了我:
osascript test.scpt dysfunctions.mindnode
missing value
非常感谢帮助。
I struggle greatly with AppleScript. I cannot even write a simple script that takes a filename and opens it in the appropriate app.
I tried this:
on run argv
tell application "MindNode"
open file (item 1 of argv)
end tell
end run
This gives me:
osascript test.scpt dysfunctions.mindnode
missing value
Very grateful for assistance.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论