none
Can a server (WOPI Host I guess) use Office Online to programmatically update a document? RRS feed

  • Question

  • Hello,

    We are brainstorming on a new project of ours and are trying to figure out all the possibilities we have in front of us.

    One key feature of our project is to be able to programmatically modify some place holder text in a word document. For example, the user would create some sort of template file and create some named placeholders (maybe use bookmarks, or similar). Let's say there would be the document title and the document's chrono index. When another user chooses to create a document from that template, our server should make a copy of the template file and give it the proper chrono index.

    There would be numerous other edit actions like so... I am just wondering if a WOPI client could be used by our server directly or would it really need human interaction? 

    Thursday, August 8, 2019 10:10 AM

Answers

  • Mathieu,

    There are other frameworks out there. I've seen framework/API's that use Ansi C, Python and some others. Some are more specific to one particular document markup like SpreadsheetML or WordprocessingML. 

    Good luck with your efforts and if you use Open XML SDK, please file issues (on the Github repo) when you find problems using the package.

    Thanks,

    Tom


    Tuesday, August 13, 2019 6:36 PM
    Moderator

All replies

  • Hello Mathieu,
    Thank you for this question. One of our engineers will investigate this and follow-up soon.

    Regards,
    Sreekanth Nadendla
    Microsoft Windows Open Specifications

    Thursday, August 8, 2019 3:24 PM
    Moderator
  • Hi Mathieu, 

    The scenario you're describing is more appropriate for a programming framework like the Open XML SDK: 

    https://github.com/OfficeDev/Open-XML-SDK

    Office Online Server and the WOPI protocol are not a programmatic file format framework but instead used to allow a file host to store documents which with be retrieved, edited and saved by the Office web applications (Word, PowerPoint, Excel Online). The interaction with the WOPI protocol does not directly offer the WOPI file host the option to programmatically manipulate the internal contents of the documents, i.e. Office Open XML markup and packaging. 

    I hope this helps.

    Best regards,
    Tom Jebo
    Sr Escalation Engineer
    Microsoft Open Specifications


    Thursday, August 8, 2019 7:08 PM
    Moderator
  • Thank you.

    We wanted to avoid this SDK as it works only for Open documents, and is made in C# which we have no experience on...

    We'll try something along those lines anyways I guess.

    Tuesday, August 13, 2019 1:10 PM
  • Mathieu,

    There are other frameworks out there. I've seen framework/API's that use Ansi C, Python and some others. Some are more specific to one particular document markup like SpreadsheetML or WordprocessingML. 

    Good luck with your efforts and if you use Open XML SDK, please file issues (on the Github repo) when you find problems using the package.

    Thanks,

    Tom


    Tuesday, August 13, 2019 6:36 PM
    Moderator