使用AppleScript阻止Excel消息“不支持的内容”

时间:2013-02-21 04:43:33

标签: excel applescript applescript-excel excel-2008

我有一个Excel 2008文件。这会在打开时发出警告消息。我希望这条消息不被显示。

tell application "Microsoft Excel"  
    open workbook workbook file name "private:var:root:Desktop:XLS FILES:Copy of 
                                   New Microsoft Excel Worksheet (5).xlsx" read only 1
end tell

使用上述脚本打开Excel文件但仍显示Excel警告:

SO14994693 question example

1 个答案:

答案 0 :(得分:0)

尝试:

tell application "Microsoft Excel"
    open workbook workbook file name "private:var:root:Desktop:XLS FILES:Copy of New Microsoft Excel Worksheet (5).xlsx" with ignore read only recommended
end tell