Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我在 Excel 中为 Office 2013 创建了一个任务窗格应用程序。它有几个按钮和标签。现在我想在点击按钮时在我的电脑上打开一个文件位置。所以请告诉我它的代码,因为我是 java-script 的新手。
据我所知,Office 的 JavaScript 中没有现有的 openFile API,但您可以使用 ajax 调用 wcf 从现有文档中获取字符串,并使用 Document.setSelectedDataAsync 方法将获取的字符串写入文档。