Saving/updating an Excel(xlam) add-in
wrote in message
Hello,
I have an Excel(xlam) add-in that I want to update, which I do from VBA
projects
I expect that xlam file will be saved with the update I have done when I
save the VBA project
But it seems that it doesn't always happen and the xlam is not updated.
The weird think is that I am quite sure that it worked well some time ago
I am certain that I look at the right xlam file
Office 2013 , W7
Any idea?
Avi
Most likely you are hitting the save button in the VBE thinking your addin
is the activeproject because one of it's modules is visible and apparently
active. However the activeproject is the one that's selected in the project
explorer window, easy to confuse.
To be sure you are saving the right project, in the immediate window do
?thisworkbook.Name 'and hit enter
and if what you think it is then do
thisworkbook.save ' and hit enter
While developing maybe include something like this (in the thisworkbook
module)
Private Sub Workbook_BeforeClose(Cancel As Boolean)
'If gbDebug Then
If Not Me.Saved Then
If MsgBox("Do you want to save " & Me.Name, vbYesNo) = vbYes Then
Me.Save
End If
End If
' End If
End Sub
Regards,
Peter T
|