[英]How to make Office Web App Server able to edit a document with Cobalt
I am trying to build my own WOPI host using ASP.NET MVC and its WebAPI functions according to this example 我试图根据此示例使用ASP.NET MVC及其WebAPI函数构建自己的WOPI主机
https://code.msdn.microsoft.com/office/Building-an-Office-Web-f98650d6 https://code.msdn.microsoft.com/office/Building-an-Office-Web-f98650d6
I successfully used that example to connect to my Office Web App Server and I can use that to access files of Excel and PowerPoint in local path and I am able to edit it, but I cannot use it to open word document in editing mode as the Post action handler isn't implemented completely without any response so that it cannot handle any edit request. 我已成功使用该示例连接到我的Office Web App Server,并且可以使用该示例在本地路径中访问Excel和PowerPoint的文件,并且可以对其进行编辑,但无法使用它以编辑模式打开Word文档,因为后动作处理程序无法完全实现而没有任何响应,因此它无法处理任何编辑请求。
In order to add support for editing of Office document, I tried this example with POST request handler based on Cobalt library extracted from Office Web App Server. 为了增加对Office文档编辑的支持,我尝试使用基于从Office Web App Server提取的Cobalt库的POST请求处理程序的此示例。
https://github.com/marx-yu/WopiHost https://github.com/marx-yu/WopiHost
With this example I managed to edit ans save all kinds of document with Office Web App Server. 在此示例中,我设法使用Office Web App Server编辑并保存了各种文档。 However, when I tried to integrate these two together I found that even if I can enter the edit window of Excel and PowerPoint and I can see that Post Requests from Office Web App Server like locking and Cobalt are handled by my WOPI Post API action handler. 但是,当我尝试将这两者整合在一起时,我发现即使我可以进入Excel和PowerPoint的编辑窗口,也可以看到我的WOPI Post API操作处理程序处理了来自Office Web App Server的发帖请求(例如锁定和Cobalt) 。 Those change doesn't take any effect on my local file at all. 这些更改完全不会对我的本地文件产生任何影响。 Moreover, I still cannot edit word document and when I checked the back log of Office Web App Server, I found the error message is Cobalt is not supported while I have already set the SupportsCobalt in CheckFileInfo response to true! 而且,我仍然无法编辑Word文档,当我检查Office Web App Server的待办事项日志时,我发现错误消息是不支持Cobalt,而我已经将CheckFileInfo响应中的SupportsCobalt设置为true! Any help is very appreciated! 任何帮助都非常感谢!
I think I have exactly what you are looking for. 我想我正是您要找的东西。 Check out my implementation of the WOPI host . 查看我对WOPI主机的实现 。 It's an MVC6 app that takes the best from the both examples you are referring to and adds some extra features. 这是一个MVC6应用程序,它可以从您所引用的两个示例中获得最大的收益,并增加了一些其他功能。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.