How To Create Word Add-Ins

Introduction

In this article, we will see how to create a word add-in and how to run it.

Word add-in is an application that we can run inside of the word to increase functionality. We can build word add-ins by using HTML, CSS, JavaScript, C#, or any other technology. It does not matter what platform we are using it will work (word for Windows, mac, web- office 365 account).

Steps to Create Word Add-in

Step 1. We need to install the Yeoman generator (yo) and generator office globally using npm.

Step 2. Run npm install -g yo generator-office to install yo and office project template generator globally.

Step 3. Run yo office command to create an add-in project.

Step 4. When you run the above command, it will ask for below information.

  1. Choose a project type: Office Add-in Task Pane project
  2. Choose a script type: JavaScript
  3. What do you want to name your add-in? My Office Add-in
  4. Which Office client application would you like to support?: Word
    Pane project

Once you complete the wizard, the generator will create the project and install supporting Node components.

Step 5. Go your project using this command cd "My Office Add-in".

Step 6. Run this command to start development server npm run dev-server.

Step 7. Run npm start this command run your add-ins.

Step 8. Once you run above command it opens word desktop apps with your add-ins. You can see your add-ins in Home Tab.

Command

Step 9. When you click on add-ins it will open side pane.

Add-ins

Conclusion

This is how we can easily create Word add-in and test it.


Similar Articles