+ Reply to Thread
Results 1 to 2 of 2

Excel crashes after closing workbook

  1. #1
    James W.
    Guest

    Excel crashes after closing workbook

    I have been experiencing a strange problem when closing one of my workbooks
    which connects to the SQL server via ado. After the workbooks with code is
    closed if another workbook is open and I click on another workbook, excel
    will crash. If however I click on outlook or another office application,
    bring it to focus and then go back to excel its fine. I have checked to make
    sure all object are being released. Any ideas...

  2. #2
    Simon Murphy
    Guest

    RE: Excel crashes after closing workbook

    James

    Make sure your code has some DoEvents in (2 or 3 sometimes) before it ends
    to allow Excel to clear the message queue. Also make sure you do not
    reference any forms, or if you do make sure to set everything to nothing.

    I have had similar probs, eventually I think it ended up being an implicit
    reference to a function in a form (should have been in a module anyway).

    cheers
    Simon

    "James W." wrote:

    > I have been experiencing a strange problem when closing one of my workbooks
    > which connects to the SQL server via ado. After the workbooks with code is
    > closed if another workbook is open and I click on another workbook, excel
    > will crash. If however I click on outlook or another office application,
    > bring it to focus and then go back to excel its fine. I have checked to make
    > sure all object are being released. Any ideas...


+ 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