How to update DocProperty fields with Word js

I am developing Office 2016 Addin using Word js 1.3. Addin allows you to define custom properties and store their value.

I would like to add a button in the UI of my Addin that updates all fields using DocProperty (see Figure 1) in the document that uses custom properties added by the user. Basically the button should update the fields (see Fig. 2).

I mean the following things:

DocProperty Field

Update Field in document

I am unable to wrap fields in ContentControls and then update them. The documents are preconfigured with some custom properties and their content cannot be changed.

+3
javascript ms-word office-js office-addins


source to share


No one has answered this question yet

Check out similar questions:

7728
How do I redirect to another web page?
7649
How does JavaScript blocking work?
7494
How can I remove a specific element from an array in JavaScript?
7432
How to check if a string contains a substring in JavaScript?
7428
How can I check if an element is hidden in jQuery?
5722
How can I remove a property from a JavaScript object?
5129
How do I return a response from an asynchronous call?
4829
How do I include a JavaScript file in another JavaScript file?
3998
How to validate an email address in JavaScript
1804
How do you display code snippets in MS Word save format and syntax highlighting?



All Articles
Loading...
X
Show
Funny
Dev
Pics