Freigeben über


No Supported Way to Deploy Outlook VBA Projects

Distributing the VBA macro by replacing the VbaProject.OTM file on target Workstation is not supported. The only supported way to share the Macro is to manually copy the code over to another machine. The couple of articles below allude the un-supportability of distributing VBA Macros:

No Supported Way to Deploy Outlook VBA Projects
https://blogs.msdn.com/b/mstehle/archive/2005/12/01/outbox-no-supported-way-to-deploy-outlook-vba-projects.aspx

Using Visual Basic for Applications in Outlook
https://msdn.microsoft.com/en-us/library/office/ff863909.aspx

"Outlook Visual Basic for Applications code was designed to be a personal macro development environment, and was not designed to be deployed or distributed. To move a project from one computer to another, for example, moving the project from your work computer to your home computer, you can export the forms and code modules from the work computer and import them to the home computer. You can also copy and paste the source code of the project to Project1 on the home computer using the Visual Basic Editor. "

When there is a need for Outlook enhancement for multiple users, our recommendation is to create an Outlook add-in for that purpose. It offers multiple features like customizing ribbon apart from using Outlook Object Model or MAPI (for a C++ add-in). I'm sharing additional info on building add-in in Outlook using Visual Studio