Cocoa Scripting Bridge 和元素
因此,我尝试编写脚本的应用程序有一个脚本定义文件,其中包含
问题是,如何使用 Scripting Bridge 获取该元素内部的内容?或者,我如何发送检索它所需的 Apple 事件,然后将我得到的内容转换回 SBObject?
我已经尝试过:
[document nameOfKey]
document.nameofKey
[document contents]
document.contents
So, the application I'm trying to script has a scripting definition file that includes a <contents> element, which is an "implicitly specified container."
The question, how do I get at what's inside this element using Scripting Bridge? Or alternatively, how do I send the Apple Event necessary to retrieve it and then transform what I get back into an SBObject?
I already tried:
[document nameOfKey]
document.nameofKey
[document contents]
document.contents
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
不确定这是否有帮助,但我注意到有时您必须使用关键字“get”才能实际获取某些内容,然后才能访问它的其他部分。所以我会尝试这个...
等等。请注意,“get”是 SBObject 的实例方法,因此您可以在文档中找到它。
Not sure if this will help but I noticed that sometimes you have to use the keyword "get" in order to actually get something before you can access other parts of it. So I would try this...
etc. Note that "get" is an instance method of SBObject so you can find it in the docs.