+ Reply to Thread
Results 1 to 3 of 3

Question: Macro to save and close workbook

  1. #1
    Registered User
    Join Date
    02-14-2011
    Location
    Muscatine, Iowa
    MS-Off Ver
    Excel 2010
    Posts
    30

    Question: Macro to save and close workbook

    Question: Macro to save and close workbook

    This is what I have come up with, I have found three issues with it.
    1. One it closes all the workbooks I have open and only saves the one that the macro is in.
    2. Two if I put this macro in more than one workbook I can’t have both open at the same time.
    3. Three I got the missage to come up You have 5 minutes to save before Excel closes. But if no one clicks that message the workbook stays open.

    Running Excel 2003 with Windows 7

    Please Login or Register  to view this content.
    Last edited by extremecorvette; 06-02-2011 at 01:25 PM.

  2. #2
    Forum Expert Mordred's Avatar
    Join Date
    07-06-2010
    Location
    Winnipeg, Canada
    MS-Off Ver
    2007, 2010
    Posts
    2,787

    Re: Question: Macro to save and close workbook

    Hi extremcorvette, Please enclose your code with code tags. To find out how, please click here and read rule # 3.
    If you're happy with someone's help, click that little star at the bottom left of their post to give them Reps.

    ---Keep on Coding in the Free World---

  3. #3
    Registered User
    Join Date
    02-14-2011
    Location
    Muscatine, Iowa
    MS-Off Ver
    Excel 2010
    Posts
    30

    Re: Question: Macro to save and close workbook

    I set it up to run 2 min and then at 1 min give the warning. It would be nice to get the WsShell.Popup to stay open for 30 sec.



    I still need to find a way to only close this one workbook and not all the others I have open. Any ideas?





    Here is the code I'm using.





    Please Login or Register  to view this content.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1