1

I'm working on an Microsoft office add-in using office.js, targeting Windows and Mac.

One of it's requirement is to modify properties like author and tags. As per the documentation host (Excel, Word etc.) specific APIs have DocumentProperty class and it's property can be accessed via context.document.properties.title as seen below,

Word.run(function (context) {
    var document = context.document;
    document.properties.load("author, title");

    return context.sync()
        .then(function () {
            console.log("The author of this document is " + document.properties.author + " and the title is '" + document.properties.title + "'");
        });
});
}

Source: stackoverflow, docs

But this API belongs to WordApi 1.3 requirement set, i.e. earliest supported version would be Office 2019.

So my question is this - is there any way to do this using common API or host specific APIs belonging to requirement set WordApi 1.1, it's important to support Office 2013 for Windows and Office 2011 for Mac. If not then what is the closest solution to ensure add-in to work on maximum of the hosts.

Prakhar Pal
  • 178
  • 7

0 Answers0