Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VBA Workbook Close very slow

Status
Not open for further replies.

foto66

Programmer
Jun 23, 2005
11
0
0
CA
I am opening up a second workbook from the main one, pasting some data over from its sheets and then closing. For some reason, the close is suddenly taking a rather long time (2 or 3 seconds). If I don't copy/paste, then it shuts down immediately. BTW--it's not the copy/paste that is taking time (I have tested this), but simply the close.

Any ideas? I have tried turning off calcualtion.

Workbooks("myWorkbook").Close SaveChanges:=False

Cheers,
Vuk.
 
Found the solution! Need to perform this operation before attempting the workbook close:

Code:
Application.CutCopyMode = False

Hope this ends up being of help to someone else.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top