PDA

View Full Version : Workbook.BeforeSave Event on Mac Office



ldoodle
02-05-2020, 07:22 AM
Hi,

I'm doing this in ThisWorkbook:



Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)

Cancel = True
Call SomeOtherSub

End Sub


On Windows Office this works fine. In Mac Office, this even does not fire when using the applications Save button. If I use the Save button in the VBA Editor window, it does work.

WTF?!!

Thanks

ldoodle
02-06-2020, 04:15 AM
Well that was annoying... the default Save button in Mac QAT doesn't fire this event. Changing it to the Save As button works a charm!

Question though... is there a SaveUI instead of SaveAsUI I need to use?