Automatically open a task pane when an add-in is installed

Harsha Vardhan Reddy 0 Reputation points
2024-03-27T01:01:38.7766667+00:00

Hi Team,

We have requirement where the task pane should open automatically when any word document is opened.

We have developed custom word add-in and the manifest.xml file is deployed under Microsoft Admin Center --> Integrated Apps

and Custom developed solution is deployed under the Azure web app and

Tried adding the below xml in manifest.xml file under admin center

<Action xsi:type="ShowTaskpane"> <TaskpaneId>Office.AutoShowTaskpaneWithDocument</TaskpaneId> <SourceLocation resid="Contoso.Taskpane.Url" /> </Action>

Added the below code index.tsx and taskpane.ts file

Office.context.document.settings.set("Office.AutoShowTaskpaneWithDocument", true); Office.context.document.settings.saveAsync();

When we run the add-in local environment using "npm start" then task pane opens automatically But after deploying with above changes the task pane not opening automatically. Are we missing anything, PFB the reference article we have tried.

https://learn.microsoft.com/en-us/office/dev/add-ins/develop/automatically-open-on-installation?source=recommendations

https://learn.microsoft.com/en-us/office/dev/add-ins/develop/automatically-open-a-task-pane-with-a-document

Microsoft 365 and Office | Development | Other
Microsoft 365 and Office | Word | For business | Windows
0 comments No comments
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.