Skip to content

‎Word Desktop: Add‑in cannot create new document from template (regression, backend call succeeds)‎ #6554

@desertfireadmin

Description

@desertfireadmin

Summary

Word Desktop appears to fail to create/open a new document from a template via our Office.js Word add-in after updating to Word Version 2505 (Build 18827.20128, Click-to-Run). The add-in loads and authenticates successfully, and the backend template request succeeds (HTTP 200 with non-trivial payload), but Word does not create/open the new document.

This worked prior to the Word update, and no add-in/backend changes were deployed.

Product / Platform

  • Host: Microsoft Word (Desktop)
  • Platform: Windows (Click-to-Run)
  • Office / Word Version: 2505
  • Build: 18827.20128
  • Add-in type: Task pane add-in (Office.js)
  • office.context.diagnostics

{host: 'Word', version: '16.0.18827.20128', platform: 'PC'}

Expected behavior

Selecting a template in the add-in should create/open a new Word document based on the template.

Actual behavior

The template download succeeds, but Word fails to create/open the new document. Behavior may be silent (no new document) or results in a generic failure during the insertion/open step.

Repro steps

  1. Open Microsoft Word Desktop (Version 2505, Build 18827.20128).
  2. Open our Word task pane add-in.
  3. Log in (auth succeeds).
  4. Choose "Create new document from template" (template stored in backend).
  5. Observe that the backend template request completes successfully (HTTP 200, payload ~42–58 KB).
  6. Word fails to open/create the new document.

Diagnostics / Evidence

  • Network trace from Edge DevTools attached to the task pane shows repeated requests like:
    template?name=<guid>-ClassicSide.docx
    • Status: 200
    • Type: XHR
    • Response sizes observed: ~42.4 KB and ~58.6 KB
    • Preflight requests succeed (CORS appears OK)
  • Clearing Office add-in cache:
    %LOCALAPPDATA%\Microsoft\Office\16.0\Wef
    did NOT resolve the issue.
  • Workaround: Opening an existing document created previously from the template and then using the add-in to edit works as expected.
  • Error log:
    main.69c897e25604f0788cbd.js:1 ERROR Error: Uncaught (in promise): TypeError: Cannot read properties of undefined (reading '_marketplaceType')
    TypeError: Cannot read properties of undefined (reading '_marketplaceType')
    at Object.value [as set] (word-win32-16.01.js:25:181241)
    at e. (main.69c897e25604f0788cbd.js:1:2332392)
    at main.69c897e25604f0788cbd.js:1:339783
    at Object.next (main.69c897e25604f0788cbd.js:1:339888)
    at a (main.69c897e25604f0788cbd.js:1:338630)
    at e.invoke (polyfills.068996c408ed4139cf2f.js:1:7310)
    at Object.onInvoke (main.69c897e25604f0788cbd.js:1:270627)
    at e.invoke (polyfills.068996c408ed4139cf2f.js:1:7250)
    at t.run (polyfills.068996c408ed4139cf2f.js:1:2410)
    at polyfills.068996c408ed4139cf2f.js:1:14331
    at e.invokeTask (polyfills.068996c408ed4139cf2f.js:1:7994)
    at Object.onInvokeTask (main.69c897e25604f0788cbd.js:1:270510)
    at e.invokeTask (polyfills.068996c408ed4139cf2f.js:1:7915)
    at t.runTask (polyfills.068996c408ed4139cf2f.js:1:3073)
    at _ (polyfills.068996c408ed4139cf2f.js:1:10310)
    at t.invokeTask [as invoke] (polyfills.068996c408ed4139cf2f.js:1:9155)
    at g (polyfills.068996c408ed4139cf2f.js:1:22175)
    at EmbeddedBrowserWebView.y (polyfills.068996c408ed4139cf2f.js:1:22408)
    at Object.value [as set] (word-win32-16.01.js:25:181241)
    at e. (main.69c897e25604f0788cbd.js:1:2332392)
    at main.69c897e25604f0788cbd.js:1:339783
    at Object.next (main.69c897e25604f0788cbd.js:1:339888)
    at a (main.69c897e25604f0788cbd.js:1:338630)
    at e.invoke (polyfills.068996c408ed4139cf2f.js:1:7310)
    at Object.onInvoke (main.69c897e25604f0788cbd.js:1:270627)
    at e.invoke (polyfills.068996c408ed4139cf2f.js:1:7250)
    at t.run (polyfills.068996c408ed4139cf2f.js:1:2410)
    at polyfills.068996c408ed4139cf2f.js:1:14331
    at e.invokeTask (polyfills.068996c408ed4139cf2f.js:1:7994)
    at Object.onInvokeTask (main.69c897e25604f0788cbd.js:1:270510)
    at e.invokeTask (polyfills.068996c408ed4139cf2f.js:1:7915)
    at t.runTask (polyfills.068996c408ed4139cf2f.js:1:3073)
    at _ (polyfills.068996c408ed4139cf2f.js:1:10310)
    at t.invokeTask [as invoke] (polyfills.068996c408ed4139cf2f.js:1:9155)
    at g (polyfills.068996c408ed4139cf2f.js:1:22175)
    at EmbeddedBrowserWebView.y (polyfills.068996c408ed4139cf2f.js:1:22408)
    at w (polyfills.068996c408ed4139cf2f.js:1:13570)
    at polyfills.068996c408ed4139cf2f.js:1:14387
    at e.invokeTask (polyfills.068996c408ed4139cf2f.js:1:7994)
    at Object.onInvokeTask (main.69c897e25604f0788cbd.js:1:270510)
    at e.invokeTask (polyfills.068996c408ed4139cf2f.js:1:7915)
    at t.runTask (polyfills.068996c408ed4139cf2f.js:1:3073)
    at _ (polyfills.068996c408ed4139cf2f.js:1:10310)
    at t.invokeTask [as invoke] (polyfills.068996c408ed4139cf2f.js:1:9155)
    at g (polyfills.068996c408ed4139cf2f.js:1:22175)

Additional diagnostics

Word API used
Our add-in creates new documents from templates using the Word API:
Document.insertFileFromBase64(...)

This was confirmed by inspecting the loaded Word runtime sources in DevTools
(searching for insertFileFromBase64 in word-win32-16.0.1.js and related files).

Template payload format
Templates are delivered as Base64 and passed directly to
Document.insertFileFromBase64 (not OOXML, not binary open).

Observation
Backend retrieval succeeds (HTTP 200 with non-trivial payload), and failure occurs
after Base64 is handed to Word for insertion, indicating a Word document
creation/insertion regression rather than a backend or add-in retrieval issue.

Impact

Customers cannot create new PPM documents from templates via the add-in on this Word build. Editing existing documents works, but this is not a viable long-term solution.

Notes / Hypothesis

This appears to be a Word Desktop regression affecting the document creation/template insertion step (e.g., Document.insertFileFromBase64 or related flow). Backend retrieval succeeds; failure occurs after retrieval when Word attempts to open/insert the template.

Additional note: As a workaround, opening an existing document and then using the
add-in to insert/update content works as expected. The failure only occurs when
creating a new document via Document.insertFileFromBase64.

Additional info requested

  • Is Word Version 2505 / Build 18827.20128 known to have regressions impacting Word add-ins that create new documents from templates?
  • Are insertFileFromBase64 APIs impacted on this build?
  • Any recommended mitigations while waiting for an Office fix?

Attachments

  • Screenshot of DevTools Network tab showing 200 responses and payload size.
  • (Can provide) minimal repro add-in if needed (template download + insert call).
    `` video showing what happens: [https://go.screenpal.com/watch/cOe1cMnZFJG]
Image

Metadata

Metadata

Assignees

Labels

Needs: author feedbackWaiting for author (creator) of Issue to provide more infoStatus: no recent activityIssue or PR is stale (no recent activity)regressionFunctionality that previously worked no longer works

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions