R
Ryan H
I have a workbook named "QUOTES" that references another workbook named "ADD
IN". ADD IN is saved as an add in, aka IsAddIn = True. I have a button in
QUOTES that changes the IsAddIn property = False which exposes the ADD IN
worksheets for editting by the user. Then when the user makes his edits and
clicks the save button I want the IsAddIn property set back to True thus
re-hidding the workbook to its orginal state. I do this in the BeforeSave
Event.
This is the problem. I make my edits, click save in ADD IN, the workbook is
hidden and everything seems fine. But for some reason when I close QUOTES I
get prompted "Do you want to save ADD IN?" If I click NO, my edits are not
saved. So for some reason ADD IN isn't saving. Why?
Sub cmbEditAddIn_Click()
' show add in workbook
With ThisWorkbook
.IsAddin = False
.Activate
End With
End Sub
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
If Cancel = False Then ThisWorkbook.IsAddin = True
End Sub
IN". ADD IN is saved as an add in, aka IsAddIn = True. I have a button in
QUOTES that changes the IsAddIn property = False which exposes the ADD IN
worksheets for editting by the user. Then when the user makes his edits and
clicks the save button I want the IsAddIn property set back to True thus
re-hidding the workbook to its orginal state. I do this in the BeforeSave
Event.
This is the problem. I make my edits, click save in ADD IN, the workbook is
hidden and everything seems fine. But for some reason when I close QUOTES I
get prompted "Do you want to save ADD IN?" If I click NO, my edits are not
saved. So for some reason ADD IN isn't saving. Why?
Sub cmbEditAddIn_Click()
' show add in workbook
With ThisWorkbook
.IsAddin = False
.Activate
End With
End Sub
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
If Cancel = False Then ThisWorkbook.IsAddin = True
End Sub