Applescript QuickTime pro 保存导出设置

发布于 2024-11-05 10:52:11 字数 523 浏览 5 评论 0原文

我正在尝试使用 AppleScript 将 Quicktime 影片的导出设置保存到文件中。这是我的代码:

set file2save to (choose file name default location (path to desktop) default name "setting.qtes")

tell application "QuickTime Player 7"
    tell document "video.mov"
        save export settings for QuickTime movie to file2save
    end tell
end tell

但我收到错误 “QuickTime Player 7 出现错误:发生了 -2107 类型的错误。”号码-2107 此错误发生在“保存导出设置”行... 我做错了什么? 谢谢。

这是屏幕截图: 在此处输入图像描述

I am trying to save export setting of Quicktime movie to a file using AppleScript. This is my code:

set file2save to (choose file name default location (path to desktop) default name "setting.qtes")

tell application "QuickTime Player 7"
    tell document "video.mov"
        save export settings for QuickTime movie to file2save
    end tell
end tell

But I get error "QuickTime Player 7 got an error: An error of type -2107 has occurred." number -2107
This error occurs on the "save export settings" line...
What am I doing wrong?
Thanks.

Here's the screenshot:
enter image description here

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

迷你仙 2024-11-12 10:52:11

据我所知,问题是不再支持函数,在字典中找不到任何有关它的内容

仍然对我不起作用,但我发现此线程 看起来可能有帮助

as far as I can tell the problem is that functions is no longer supported can't find anything regarding it in the dictionary

still wasn't working for me but I foundthis thread which looks like it may help

把梦留给海 2024-11-12 10:52:11

这对我有用。您可以看到我从 Quicktime 获取了文档名称以确保其正确,因此您的问题在于文档名称。请注意,如果电影位于最前面,那么您还可以使用“讲述第一个文档”等术语。

set file2save to (choose file name default location (path to desktop) default name "setting.qtes")

tell application "QuickTime Player 7"
    set docName to name of first document
    tell document docName
        save export settings for QuickTime movie to file2save
    end tell
end tell

This works for me. You can see that I got the doc name from Quicktime to make sure it was correct, so your problem is with the document name. Note that if the movie is frontmost then you can also use terms like "tell first document".

set file2save to (choose file name default location (path to desktop) default name "setting.qtes")

tell application "QuickTime Player 7"
    set docName to name of first document
    tell document docName
        save export settings for QuickTime movie to file2save
    end tell
end tell
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文