workbook close event

  1. L

    .SaveAs doesn't initate 'Workbook_BeforeClose' ?

    Hi all, I am working on a macro that makes users click "Enable Content" mandatorily to access the workbook, works like a charm, except I have a macro which does a .SaveAs under a different name, and it automatically closes my original file, but doesn't initiate the "Workbook_BeforeClose" code I...
  2. xlhelp15

    Any idea of how to close list of workbooks using VBA ?

    Hello Genius - Is there a way to close list of workbooks using VBA ? Have tried the way of Workbooks("sample1").close but it closed only the sample1 WB. I need to close Sample1, Sample5, Sample12 in a row when I click the command button. Thank you for considering my request.
  3. H

    Workbook close when Hidden not working - dynamic file location/filename

    Hey everyone, This has been bustin my balls all day. I have a workbook which when opened, also opens another workbook which has visible = false set. When i exit the main workbook, the other workbook does not close. I have tried multiple things to get it to close without luck. I need a...
  4. C

    Close the save dialogue without breaking my VBA

    Excel 2010 So I have some complex (to me) VBA code that I retrieved from here: from user Nirvana_. The code's purpose is to look through a directory of excel files, and...
  5. C

    Determine if any other workbook is open?

    Is there a way to determine if there is any other excel workbook open? This is what I'm trying to do. I have an auto_open module that does a routine and then exits excel. I was using application.quit, but that closes all of my excel workbooks (I don't want this). I then tried...
  6. C

    Workbook_BeforeClose event to apply to active workbook

    I have a workbook with code that disables cut copy and paste which works fine. On opening the code disables these functions and on closing it enables them. However if I have two workbooks open with this code and I shut one of the workbooks it then enables cut copy and paste in the remaining...

Some videos you may like

This Week's Hot Topics