+ Reply to Thread
Results 1 to 5 of 5

Close active File and Active window

  1. #1
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,239

    Close active File and Active window

    Hi Guys...

    This is probably very basic but have not yet come across a solution...
    I always make use of this code for closing my designed excel applications, however this closes all excel files

    Please Login or Register  to view this content.
    This code leaves a grey window open...what code can i make use of to close my file and It's active window without closing all excel files?
    Please Login or Register  to view this content.
    Last edited by sintek; 01-14-2019 at 11:24 AM.
    Good Luck
    I don't presume to know what I am doing, however, just like you, I too started somewhere...
    One-day, One-problem at a time!!!
    If you feel I have helped, please click on the star to left of post [Add Reputation]
    Also....add a comment if you like!!!!
    And remember...Mark Thread as Solved.
    Excel Forum Rocks!!!

  2. #2
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,239

    Re: Close active File and Active window

    This seems to work...Anyone have a better solution...

    Please Login or Register  to view this content.
    Last edited by sintek; 01-14-2019 at 11:24 AM.

  3. #3
    Forum Expert Arkadi's Avatar
    Join Date
    02-13-2014
    Location
    Smiths Falls, Ontario, Canada
    MS-Off Ver
    Office 365
    Posts
    5,059

    Re: Close active File and Active window

    To work around that I usually use something like:

    Please Login or Register  to view this content.
    Please help by:

    Marking threads as closed once your issue is resolved. How? The Thread Tools at the top
    Any reputation (*) points appreciated. Not just by me, but by all those helping, so if you found someone's input useful, please take a second to click the * at the bottom left to let them know

    There are 10 kinds of people in this world... those who understand binary, and those who don't.

  4. #4
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,239

    Re: Close active File and Active window

    Arkadi...

    Make use of it I will...Clean & simplistic it is...

    Thank you

  5. #5
    Forum Expert Arkadi's Avatar
    Join Date
    02-13-2014
    Location
    Smiths Falls, Ontario, Canada
    MS-Off Ver
    Office 365
    Posts
    5,059

    Re: Close active File and Active window

    Lol, love the syntax sintek

    Thanks for the rep!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Change VBA code for a specific window to any active window
    By dawondr in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-25-2016, 04:00 PM
  2. Switch from Active Window to Variable Window/Rename Varaible Sheet
    By CravingGod in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 02-04-2016, 09:52 AM
  3. Save file so that next time it's opened Range A1 is active and in the window?
    By dmasters4919 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 06-18-2015, 11:27 AM
  4. resize active window ie: add to the height of the active window
    By hopefulhart in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-07-2014, 01:55 AM
  5. Replies: 1
    Last Post: 01-04-2014, 06:37 PM
  6. Close only active file and not all excel files
    By lfmemp in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 11-29-2012, 04:11 PM
  7. keystroke to close active workbook window
    By Vickie in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 12-07-2005, 07:25 PM

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