User`s guide

3 Usage Examples
Call RemoveFourierMenuItem
'Find Tools menu
Set ToolsMenu = Application.CommandBars(1).FindControl(ID:=30007)
If ToolsMenu Is Nothing Then Exit Sub
'Add Spectral Analysis menu item
Set NewMenuItem = ToolsMenu.Controls.Add(Type:=msoControlButton)
NewMenuItem.Caption = "Spectral Analysis..."
NewMenuItem.OnAction = "LoadFourier"
End Sub
Private Sub RemoveFourierMenuItem()
Dim CmdBar As CommandBar
Dim Ctrl As CommandBarControl
On Error Resume Next
'Find tools menu and remove Spectral Analysis menu item
Set CmdBar = Application.CommandBars(1)
Set Ctrl = CmdBar.FindControl(ID:=30007)
Call Ctrl.Controls("Spectral Analysis...").Delete
End Sub
3 Save the a dd-in.
Now that the VBA coding is com plete, you can save the add-in. Save this
file into the
<project-directory>\distrib directory that D eployment
Tool created when building the project. Here,
<project-directory> refers
to the project directory that D eployment Too l used to save the Fourier
project. Name the add-in
Spectral Analysis.
a. From the Excel main me nu, select File > Properties.
b. When the Workbo ok Properties dialog box appears, click the
Summary tab, and enter
Spectral Analysis as the workbook title.
c. Click OK to save the edits.
d. From the Excel main menu, select File > Save As.
e. WhentheSaveAsdialogboxappears,select
Microsoft
Excel Add-In (*.xla)
asthefiletype,andbrowseto
<project-directory>\distrib.
f. Enter
Fourier.xla as the file name and click Save to save the add-in.
3-26