Using the VB Editor to Convert a File to an AddIn

The former method is great if you are creating an add-in for your own use. However, if you are creating an add-in for a client, you probably want to keep the add-in stored in a folder with all the client's application files. It is fairly easy to bypass the Save As method and create an add-in using the Visual Basic Editor.

Open the workbook that you want to convert to an add-in. Switch to the Visual Basic Editor. In the project explorer, double-click on ThisWorkbook. In the Properties window, find the property called IsAddIn and change its value to True, as shown in Figure 25.3.

Figure 25.3

Creating an add-in is as simple as changing the IsAddIn property of ThisWorkbook.

Figure 25.3

Creating an add-in is as simple as changing the IsAddIn property of ThisWorkbook.

Press Ctrl+G to display the Immediate window. In the Immediate window, save the file, using an .xla extension:

ThisWorkbook.SaveAs FileName:="C:\ClientFiles\Chap25.xla", FileFormat:=xlAddIn

You've now successfully created an add-in in the client folder that you can easily find and email to your client.

0 0

Post a comment