diff --git a/Excel-Add-in-ChartAPI-Anylysis-Data/README.md b/Excel-Add-in-ChartAPI-Anylysis-Data/README.md index 4530bec..16cd607 100644 --- a/Excel-Add-in-ChartAPI-Anylysis-Data/README.md +++ b/Excel-Add-in-ChartAPI-Anylysis-Data/README.md @@ -71,9 +71,6 @@ These are the important files in the sample project. | README.md | RUN_WITH_EXTENSION.md | src/ Add-in source code -| | commands/ -| | | commands.html -| | | commands.ts | | taskpane/ | | | taskpane.css Task pane style | | | taskpane.html Task pane entry HTML diff --git a/Excel-Add-in-ChartAPI-Anylysis-Data/manifest.xml b/Excel-Add-in-ChartAPI-Anylysis-Data/manifest.xml index be9c847..217a1be 100644 --- a/Excel-Add-in-ChartAPI-Anylysis-Data/manifest.xml +++ b/Excel-Add-in-ChartAPI-Anylysis-Data/manifest.xml @@ -28,7 +28,6 @@ - @@ -68,7 +67,6 @@ - diff --git a/Excel-Add-in-ChartAPI-Anylysis-Data/src/commands/commands.html b/Excel-Add-in-ChartAPI-Anylysis-Data/src/commands/commands.html deleted file mode 100644 index 495d471..0000000 --- a/Excel-Add-in-ChartAPI-Anylysis-Data/src/commands/commands.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Excel-Add-in-ChartAPI-Anylysis-Data/src/commands/commands.ts b/Excel-Add-in-ChartAPI-Anylysis-Data/src/commands/commands.ts deleted file mode 100644 index f818255..0000000 --- a/Excel-Add-in-ChartAPI-Anylysis-Data/src/commands/commands.ts +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. - * See LICENSE in the project root for license information. - */ - -/* global Office */ - -Office.onReady(() => { - // If needed, Office.js is ready to be called. -}); - -/** - * Shows a notification when the add-in command is executed. - * @param event - */ -function action(event: Office.AddinCommands.Event) { - const message: Office.NotificationMessageDetails = { - type: Office.MailboxEnums.ItemNotificationMessageType.InformationalMessage, - message: "Performed action.", - icon: "Icon.80x80", - persistent: true, - }; - - // Show a notification message. - Office.context.mailbox.item.notificationMessages.replaceAsync("ActionPerformanceNotification", message); - - // Be sure to indicate when the add-in command function is complete. - event.completed(); -} - -// Register the function with Office. -Office.actions.associate("action", action); diff --git a/Excel-Add-in-Custom-Function-Using-WebWorker/README.md b/Excel-Add-in-Custom-Function-Using-WebWorker/README.md index 5a8824a..b1c9e73 100644 --- a/Excel-Add-in-Custom-Function-Using-WebWorker/README.md +++ b/Excel-Add-in-Custom-Function-Using-WebWorker/README.md @@ -81,8 +81,6 @@ These are the important files in the sample project. | RUN_WITH_EXTENSION.md | SECURITY.md | src/ Add-ins source code -| | commands/ -| | | commands.js | | taskpane/ | | | taskpane.html Task pane entry HTML | | | taskpane.js Add API calls and logic here diff --git a/Excel-Add-in-Custom-Function-Using-WebWorker/src/commands/commands.js b/Excel-Add-in-Custom-Function-Using-WebWorker/src/commands/commands.js deleted file mode 100644 index 50d8ac6..0000000 --- a/Excel-Add-in-Custom-Function-Using-WebWorker/src/commands/commands.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. - * See LICENSE in the project root for license information. - */ - -/* global Office */ - -Office.onReady(() => { - // If needed, Office.js is ready to be called. -}); - -/** - * Shows a notification when the add-in command is executed. - * @param event - */ -function action(event) { - const message = { - type: Office.MailboxEnums.ItemNotificationMessageType.InformationalMessage, - message: "Performed action.", - icon: "Icon.80x80", - persistent: true, - }; - - // Show a notification message. - Office.context.mailbox.item.notificationMessages.replaceAsync("action", message); - - // Be sure to indicate when the add-in command function is complete. - event.completed(); -} - -// Register the function with Office. -Office.actions.associate("action", action); diff --git a/Excel-Add-in-ShapeAPI-Dashboard/README.md b/Excel-Add-in-ShapeAPI-Dashboard/README.md index deb2665..49c3510 100644 --- a/Excel-Add-in-ShapeAPI-Dashboard/README.md +++ b/Excel-Add-in-ShapeAPI-Dashboard/README.md @@ -71,9 +71,6 @@ These are the important files in the sample project. | README.md | RUN_WITH_EXTENSION.md | src/ Add-in source code -| | commands/ -| | | commands.html -| | | commands.ts | | taskpane/ | | | taskpane.css Task pane style | | | taskpane.html Task pane entry HTML diff --git a/Excel-Add-in-ShapeAPI-Dashboard/manifest.xml b/Excel-Add-in-ShapeAPI-Dashboard/manifest.xml index afa6770..25f8b71 100644 --- a/Excel-Add-in-ShapeAPI-Dashboard/manifest.xml +++ b/Excel-Add-in-ShapeAPI-Dashboard/manifest.xml @@ -28,7 +28,6 @@ - @@ -68,7 +67,6 @@ - diff --git a/Excel-Add-in-ShapeAPI-Dashboard/src/commands/commands.html b/Excel-Add-in-ShapeAPI-Dashboard/src/commands/commands.html deleted file mode 100644 index 495d471..0000000 --- a/Excel-Add-in-ShapeAPI-Dashboard/src/commands/commands.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Excel-Add-in-ShapeAPI-Dashboard/src/commands/commands.ts b/Excel-Add-in-ShapeAPI-Dashboard/src/commands/commands.ts deleted file mode 100644 index f818255..0000000 --- a/Excel-Add-in-ShapeAPI-Dashboard/src/commands/commands.ts +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. - * See LICENSE in the project root for license information. - */ - -/* global Office */ - -Office.onReady(() => { - // If needed, Office.js is ready to be called. -}); - -/** - * Shows a notification when the add-in command is executed. - * @param event - */ -function action(event: Office.AddinCommands.Event) { - const message: Office.NotificationMessageDetails = { - type: Office.MailboxEnums.ItemNotificationMessageType.InformationalMessage, - message: "Performed action.", - icon: "Icon.80x80", - persistent: true, - }; - - // Show a notification message. - Office.context.mailbox.item.notificationMessages.replaceAsync("ActionPerformanceNotification", message); - - // Be sure to indicate when the add-in command function is complete. - event.completed(); -} - -// Register the function with Office. -Office.actions.associate("action", action); diff --git a/Excel-HelloWorld-TaskPane-JS/README.md b/Excel-HelloWorld-TaskPane-JS/README.md index cd6c571..75cb12e 100644 --- a/Excel-HelloWorld-TaskPane-JS/README.md +++ b/Excel-HelloWorld-TaskPane-JS/README.md @@ -65,9 +65,6 @@ These are the important files in the sample project. | README.md | RUN_WITH_EXTENSION.md | src/ Add-in source code -| | commands/ -| | | commands.html -| | | commands.js | | taskpane/ | | | taskpane.css Task pane style | | | taskpane.html Task pane entry HTML diff --git a/Excel-HelloWorld-TaskPane-JS/manifest.xml b/Excel-HelloWorld-TaskPane-JS/manifest.xml index f5fd08b..90d2a26 100644 --- a/Excel-HelloWorld-TaskPane-JS/manifest.xml +++ b/Excel-HelloWorld-TaskPane-JS/manifest.xml @@ -28,7 +28,6 @@ - @@ -68,7 +67,6 @@ - diff --git a/Excel-HelloWorld-TaskPane-JS/src/commands/commands.html b/Excel-HelloWorld-TaskPane-JS/src/commands/commands.html deleted file mode 100644 index 495d471..0000000 --- a/Excel-HelloWorld-TaskPane-JS/src/commands/commands.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Excel-HelloWorld-TaskPane-JS/src/commands/commands.js b/Excel-HelloWorld-TaskPane-JS/src/commands/commands.js deleted file mode 100644 index a9dd0b7..0000000 --- a/Excel-HelloWorld-TaskPane-JS/src/commands/commands.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. - * See LICENSE in the project root for license information. - */ - -/* global Office */ - -Office.onReady(() => { - // If needed, Office.js is ready to be called. -}); - -/** - * Shows a notification when the add-in command is executed. - * @param event {Office.AddinCommands.Event} - */ -function action(event) { - const message = { - type: Office.MailboxEnums.ItemNotificationMessageType.InformationalMessage, - message: "Performed action.", - icon: "Icon.80x80", - persistent: true, - }; - - // Show a notification message. - Office.context.mailbox.item.notificationMessages.replaceAsync("action", message); - - // Be sure to indicate when the add-in command function is complete. - event.completed(); -} - -// Register the function with Office. -Office.actions.associate("action", action); diff --git a/Word-Add-in-AIGC/README.md b/Word-Add-in-AIGC/README.md index d87f5dc..84edd13 100644 --- a/Word-Add-in-AIGC/README.md +++ b/Word-Add-in-AIGC/README.md @@ -78,8 +78,6 @@ These are the important files in the sample project. | README.md | RUN_WITH_EXTENSION.md | src/ Add-ins source code -| | commands/ -| | | commands.ts | | taskpane/ | | | components/ React components | | | css/ Task pane style diff --git a/Word-Add-in-AIGC/manifest.xml b/Word-Add-in-AIGC/manifest.xml index 2aff8ae..c679b11 100644 --- a/Word-Add-in-AIGC/manifest.xml +++ b/Word-Add-in-AIGC/manifest.xml @@ -36,7 +36,6 @@ - @@ -76,7 +75,6 @@ - diff --git a/Word-Add-in-AIGC/src/commands/commands.ts b/Word-Add-in-AIGC/src/commands/commands.ts deleted file mode 100644 index 109b438..0000000 --- a/Word-Add-in-AIGC/src/commands/commands.ts +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. - * See LICENSE in the project root for license information. - */ - -/* global global, Office, self, window */ - -Office.onReady(() => { - // If needed, Office.js is ready to be called -}); - -/** - * Shows a notification when the add-in command is executed. - * @param event - */ -function action(event: Office.AddinCommands.Event) { - const message: Office.NotificationMessageDetails = { - type: Office.MailboxEnums.ItemNotificationMessageType.InformationalMessage, - message: "Performed action.", - icon: "Icon.80x80", - persistent: true, - }; - - // Show a notification message - Office.context.mailbox.item.notificationMessages.replaceAsync("action", message); - - // Be sure to indicate when the add-in command function is complete - event.completed(); -} - -function getGlobal() { - return typeof self !== "undefined" - ? self - : typeof window !== "undefined" - ? window - : typeof global !== "undefined" - ? global - : undefined; -} - -const g = getGlobal() as any; - -// The add-in command functions need to be available in global scope -g.action = action; diff --git a/Word-Add-in-WritingAssistant/README.md b/Word-Add-in-WritingAssistant/README.md index 0803f8e..ffe8b89 100644 --- a/Word-Add-in-WritingAssistant/README.md +++ b/Word-Add-in-WritingAssistant/README.md @@ -71,9 +71,6 @@ These are the important files in the sample project. | README.md | RUN_WITH_EXTENSION.md | src/ Add-ins source code -| | commands/ -| | | commands.html -| | | commands.ts | | taskpane/ | | | componets/ React components used in this sample | | | |Annotations.tsx diff --git a/Word-Add-in-WritingAssistant/manifest.xml b/Word-Add-in-WritingAssistant/manifest.xml index 2b766b0..8ee5267 100644 --- a/Word-Add-in-WritingAssistant/manifest.xml +++ b/Word-Add-in-WritingAssistant/manifest.xml @@ -28,7 +28,6 @@ - @@ -68,7 +67,6 @@ - diff --git a/Word-Add-in-WritingAssistant/src/commands/commands.html b/Word-Add-in-WritingAssistant/src/commands/commands.html deleted file mode 100644 index b3182af..0000000 --- a/Word-Add-in-WritingAssistant/src/commands/commands.html +++ /dev/null @@ -1,19 +0,0 @@ -@@ -1,18 +0,0 @@ - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Word-Add-in-WritingAssistant/src/commands/commands.ts b/Word-Add-in-WritingAssistant/src/commands/commands.ts deleted file mode 100644 index ff86d15..0000000 --- a/Word-Add-in-WritingAssistant/src/commands/commands.ts +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. - * See LICENSE in the project root for license information. - */ - -/* global Office */ - -Office.onReady(() => { - // If needed, Office.js is ready to be called. -}); - -/** - * Shows a notification when the add-in command is executed. - * @param event - */ -function action(event: Office.AddinCommands.Event) { - const message: Office.NotificationMessageDetails = { - type: Office.MailboxEnums.ItemNotificationMessageType.InformationalMessage, - message: "Performed action.", - icon: "Icon.80x80", - persistent: true, - }; - - // Show a notification message. - Office.context.mailbox.item.notificationMessages.replaceAsync("action", message); - - // Be sure to indicate when the add-in command function is complete. - event.completed(); -} - -// Register the function with Office. -Office.actions.associate("action", action); diff --git a/Word-HelloWorld-TaskPane-JS/README.md b/Word-HelloWorld-TaskPane-JS/README.md index 261b532..bf2b8e6 100644 --- a/Word-HelloWorld-TaskPane-JS/README.md +++ b/Word-HelloWorld-TaskPane-JS/README.md @@ -64,9 +64,6 @@ These are the important files in the sample project. | README.md | RUN_WITH_EXTENSION.md | src/ Add-in source code -| | commands/ -| | | commands.html -| | | commands.js | | taskpane/ | | | taskpane.css Task pane style | | | taskpane.html Task pane entry html diff --git a/Word-HelloWorld-TaskPane-JS/manifest.xml b/Word-HelloWorld-TaskPane-JS/manifest.xml index be9781f..44ed93f 100644 --- a/Word-HelloWorld-TaskPane-JS/manifest.xml +++ b/Word-HelloWorld-TaskPane-JS/manifest.xml @@ -28,7 +28,6 @@ - @@ -68,7 +67,6 @@ - diff --git a/Word-HelloWorld-TaskPane-JS/src/commands/commands.html b/Word-HelloWorld-TaskPane-JS/src/commands/commands.html deleted file mode 100644 index 495d471..0000000 --- a/Word-HelloWorld-TaskPane-JS/src/commands/commands.html +++ /dev/null @@ -1,18 +0,0 @@ - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/Word-HelloWorld-TaskPane-JS/src/commands/commands.js b/Word-HelloWorld-TaskPane-JS/src/commands/commands.js deleted file mode 100644 index a9dd0b7..0000000 --- a/Word-HelloWorld-TaskPane-JS/src/commands/commands.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license. - * See LICENSE in the project root for license information. - */ - -/* global Office */ - -Office.onReady(() => { - // If needed, Office.js is ready to be called. -}); - -/** - * Shows a notification when the add-in command is executed. - * @param event {Office.AddinCommands.Event} - */ -function action(event) { - const message = { - type: Office.MailboxEnums.ItemNotificationMessageType.InformationalMessage, - message: "Performed action.", - icon: "Icon.80x80", - persistent: true, - }; - - // Show a notification message. - Office.context.mailbox.item.notificationMessages.replaceAsync("action", message); - - // Be sure to indicate when the add-in command function is complete. - event.completed(); -} - -// Register the function with Office. -Office.actions.associate("action", action);