1,091 questions with Microsoft 365 and Office | Development | Office JavaScript API tags
Office-js NPM package
The Microsoft Office-JS NPM at https://www.npmjs.com/package/@microsoft/office-js says "The NPM package associated with this repo is no longer officially supported." Does this mean the NPM package will no longer provide the latest source…
Microsoft 365 and Office | Development | Office JavaScript API
Automating Italian salary breakdowns in Excel using online calculation data
Hi everyone, I’m setting up an Excel payroll template for Italian employees where I want to automatically show net salary, tax deductions, and contributions once the gross salary is entered. Right now, I’m using data and reference values from , since it…
Microsoft 365 and Office | Development | Office JavaScript API
Teams custom app fails to load after integrating Azure AD authentica
I’m developing a custom Teams app that integrates with Azure AD for user authentication. The app worked correctly in the development tenant, but after adding Azure AD sign-in using MSAL.js, the app intermittently fails to load inside Teams with the error…
Microsoft 365 and Office | Development | Office JavaScript API
How to apply PowerPoint template (.POTX/.PPTX) to existing slides using Office.js API?
I am developing a PowerPoint Add-in using the Office JavaScript API. I want to apply a PowerPoint template (POTX or PPTX) to the user’s current presentation without adding or replacing slides — basically, I want to apply the new design/theme to the…
Microsoft 365 and Office | Development | Office JavaScript API
Office Add-in offline installation
Hi everyone, Many of our (enterprise) clients have blocked the Microsoft AppSource for their users and would prefer an application installer that does not require loading the add-in via AppSource. It would be great to also be able to deploy…
Microsoft 365 and Office | Development | Office JavaScript API
Microsoft 365 and Office | Development | Microsoft 365 Publishing
 
	
			  Excel Add-In read cell in another workbook
It does not seem to be possible to read the contents of another workbook using the Excel JavaScript API. It seems you only have access to the workbook where the Add-In is executing. Is that correct? I have read the section of the documentation “Work with…
Microsoft 365 and Office | Development | Office JavaScript API
Always I am getting 401 error when I want to send mail through graph API, while it is generating token successfully
This is my node js code as below import axios from 'axios'; import { ConfidentialClientApplication, LogLevel } from '@azure/msal-node'; // Static configuration per your request const clientId = '****'; const clientSecret = '*******'; const tenantId =…
Microsoft 365 and Office | Development | Office JavaScript API
How to apply PowerPoint template (POTX/PPTX) to existing slides using Office.js without replacing content?
Hi team, I’m developing a PowerPoint Add-in (taskpane app) using the Office.js PowerPoint JavaScript API. My goal is to allow users to apply uploaded PowerPoint templates (PPTX or POTX) from our backend to their currently open presentation — ideally…
Microsoft 365 and Office | Development | Office JavaScript API
Issue with getAttachmentContentAsync when trying to fetch inline image attachment content
I am working on an outlook web add-in and encountered an issue with getAttachmentContentAsync. My goal is to retrieve all mail content, including inline attachments, when a mail is sent. Retrieving inline images upon sending the mail is the issue I am…
Microsoft 365 and Office | Development | Office JavaScript API
onMessageSendHandler re-executes after PromptUser override for inline attachments (Desktop Only)
Context: The issue occurs in an Outlook Mail Compose Add-in using the onMessageSendHandler function (which handles the ItemSend event). The code is adapted from the official documentation: "Automatically check for an attachment before a message is…
Microsoft 365 and Office | Development | Office JavaScript API
Graph API /me/messages/{id} returns 404 for specific users (works for others)
I am reaching out regarding an issue we're experiencing with the Microsoft Graph API for certain users. We are able to successfully call the following endpoint to retrieve messages: GET https://graph.microsoft.com/v1.0/me/messages However, when we…
Microsoft 365 and Office | Development | Office JavaScript API
Registered outlook add-in doesn't appear in new outlook windows app and on outlook web
Hello! I'm running into an issue trying to create a custom installed outlook addin. I used the yo office generator and I chose Office Add-in task pane project, typescript, outlook and Add-in only manifest. I executed the npm run start command and…
Microsoft 365 and Office | Development | Office JavaScript API
Graph AP without userinteaction
To read all emails from a Microsoft 365 account using the Graph API, I want to implement this without user interaction and with a one-time configuration. Can you provide the necessary steps?
Microsoft 365 and Office | Development | Office JavaScript API
Troubleshooting custom keyboard shortcuts with Powerpoint add-in on Mac
Hi, I've followed the following guides to set up custom keyboard shortcuts for a Powerpoint add-in. It should all be ready to go. https://free.blessedness.top/en-us/office/dev/add-ins/design/keyboard-shortcuts …
Microsoft 365 and Office | Development | Office JavaScript API
Microsoft 365 and Office | Development | Other
MS Graph: How to resolve : Forbidden - 403 - 191 ms Either the signed-in user does not have sufficient privileges, or you need to consent to one of the permissions on the Modify permissions tab
I am getting below error: Forbidden - 403 - 191 ms Either the signed-in user does not have sufficient privileges, or you need to consent to one of the permissions on the Modify permissions…
Microsoft 365 and Office | Development | Office JavaScript API
Cross tenant shared file download programmatically
Use case : I need to access files shared by a user in an external tenant programmatically. For getting user delegated token I have given files.read.all , and im usign microsoft graph node sdk , for accessing cross tenant files, even if the file was…
Microsoft 365 and Office | Development | Office JavaScript API
Clarification of hostVersion and Office Build Version Equivalence for License Type Detection in Outlook Add-ins
I am developing telemetry to differentiate between volume-licensed and retail installations of Office 2016/2019 based on version information available in Outlook add-ins. We currently use Office.context.mailbox.diagnostics.hostVersion to capture the…
Microsoft 365 and Office | Development | Office JavaScript API
Theme apply on Microsoft Excel Web Addin.
I want to build a features which will fetch 4/5 theme details from a backend and when user will click on a particular colour palate then the theme should be applied on the current workbook. I was trying to apply the theme in current workbook but observed…
Microsoft 365 and Office | Development | Office JavaScript API
Guidance on IE11 Support and User Detection for Outlook Add-in Migration to Angular 19
We are in the process of migrating our Outlook Add-in from AngularJS to Angular 19. Since Angular 12 and later versions have dropped support for IE11, we want to ensure a smooth transition for our users. Currently, we have checked for IE11 users on…
Microsoft 365 and Office | Development | Office JavaScript API
If my account is deleted, will my office scripts within a Teams team also be deleted?
I've created multiple Office scripts for my organization, and I've shared these scripts with a Teams team. If my account is deleted, will these scripts on this site also be deleted? And if they are deleted, how can I prevent the scripts from being…