OfficeDev / office-js

A repo and NPM package for Office.js, corresponding to a copy of what gets published to the official "evergreen" Office.js CDN, at https://appsforoffice.microsoft.com/lib/1/hosted/office.js.
https://learn.microsoft.com/javascript/api/overview
Other
671 stars 96 forks source link

Office JS add-ins for Word / Excel / PowerPoint - Insert tag automatically into document #2812

Closed MajuMadhusudanan closed 2 years ago

MajuMadhusudanan commented 2 years ago

Hi,

I would like to insert a tag in body part of the document or footer of the document when user opens document from a directory. We are into enterprise content management software and stores document and manages it.

There is a use case with word / excel / PowerPoint apps. When user downloads a document from store to local directory and opens its from directory, we want to insert a tag into the body part of the document or footer of the document. This use case is common in document management system. Basically the tag indicates a unique identifier with supporting information about the document.

Is there anyway to insert a tag when user open a document? Any events or callback support it?

jipyua commented 2 years ago

hi, do you must insert a "tag" into the body part of the document which is someplace together with the paragraphs? Can you insert as some setting which is not visible from UI but you can get and set them freely? Please refer here for details: https://docs.microsoft.com/en-us/javascript/api/office/office.settings?view=common-js-preview

If you need events to notify the document open, I am afraid so far there is no such event across WXP JavaScript API. We track Office Add-in feature requests on the Ideas Forum: https://aka.ms/m365dev-suggestions. please feel free to add one for this request.

ghost commented 2 years ago

This issue has been automatically marked as stale because it is marked as needing author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment. Thank you for your interest in Office Add-ins!

ghost commented 2 years ago

This issue has been closed due to inactivity. Please comment if you still need assistance and we'll re-open the issue.