2014-09-23 32 views
0

我想将我的数字表格的富文本单元格内容转换为其他格式,如Markdown或HTML。但是,我如何获得更多纯文本?Hot在电话中获取单元格的丰富文本

也许有解决方法如何设置选择范围并将其作为rtf复制到剪贴板。

tell application "Numbers" 
    get formatted value of cell 2 of row 2 of table 1 of sheet 1 of document of window 1 
end tell 
+0

选择单元格,然后调用拷贝到剪贴板。 – jweaks 2014-09-24 02:45:22

回答

0

这里有一个脚本来选择单元格,然后将内容复制到它保留了格式化剪贴板:

tell application "Numbers" 
    tell table 1 of sheet 1 of document of window 1 
     activate 
     set selection range to cell 2 of row "2" --range "B2:B2" 
    end tell 

    tell application "System Events" 
     tell process "Numbers" 
      keystroke "c" using command down 
     end tell 
    end tell 
end tell 
+0

谢谢。慢,但它的作品。 – Nebula 2014-09-25 14:01:15