Results 1 to 3 of 3
  1. #1
    Silver Lounger
    Join Date
    Jan 2001
    Location
    Northern, California, USA
    Posts
    1,886
    Thanks
    0
    Thanked 0 Times in 0 Posts

    System Crash/Reboot Coverage (97 SR2)

    I'm looking for your ideas on what to do...

    I've got a userform which is linked to a spreadsheet. My users enter thier call data into this userform. The sheet behind the form, we'll call it 'Main' is saved after every row of data is entered.

    The entire sheet (form/code included) is saved at the end of the day. I've worked out a crude recovery method that opens the backedup worksheet, copies out its contents, and pastes it back into the main sheet should the system crash. The problem i'm having is how do I make VBA recognize that the system has crashed?

    I thought perhaps a series of variables which, when the system operates normally, would change to reflect the status of the system. The problem with this is, the variables may state that the system is OK one minute, the system crashes the next, and when re-loaded, the workbook has no idea an error occured. (resulting in a loss of data... )

    I think i've thought myself into a hole on this one.. any help you can provide, ideas or otherwise would be Greatly appreciated!

    Regards,
    <IMG SRC=http://www.wopr.com/w3tuserpics/Kel_sig.gif>
    Moderator:<font color=448800> Pix Place, Internet Explorer</font color=448800>
    <small>www.kvisions.com

  2. #2
    Bronze Lounger
    Join Date
    Jun 2001
    Location
    New York, New York, Lebanon
    Posts
    1,449
    Thanks
    1
    Thanked 1 Time in 1 Post

    Re: System Crash/Reboot Coverage (97 SR2)

    DrkRealm

    I know you are pushing the envelop here, but I don't see any way to tell Excel/VBA that it crashed. Essentaily a crash is an application eror that could not be handled.

    I suggest you write something to the workbook worksheet after it successfuly saved, then if you don't see that you know it failed.

    Vraiables are reset when you re-run the code, you need something that sticks in the worksheet after it was saved. I suggest in a column add the date and time of the last save and then test for that. if you have a time and date then it was saved at least 10 seconds before that time, if not it crashed.

    Good luck.

    Wassim
    <img src=/S/compute.gif border=0 alt=compute width=40 height=20> in the <img src=/S/bagged.gif border=0 alt=bagged width=22 height=22>

  3. #3
    Bronze Lounger
    Join Date
    Jun 2001
    Location
    New York, New York, Lebanon
    Posts
    1,449
    Thanks
    1
    Thanked 1 Time in 1 Post

    Re: System Crash/Reboot Coverage (97 SR2)

    DrkRealm

    OK after some digging I found what could be the beginning of the thread.

    OK so:
    1) What if we find out what processes are running at the beginning of the application. We grab a list of them.
    2) Then we keep monitoring what processes are running say every 5 minutes. We compare the list to what we have in step 1.
    3) If the lists are the same, we continue until the next check happens, otherwise we tell the user that the application has failed. Then we can launch it and find out what was the last entry and then go to the missing entries and add them and continue.

    To see how to get the list of running processes check this MSKB article <A target="_blank" HREF=http://support.microsoft.com/support/kb/articles/q187/9/13.asp> Q187913</A>.

    This article covers the version for most Windows running today, or I hope...

    But if you are launching Excel from a VB application, then you can do some things via OLE. I will ask an OLE expert and get back to you.

    Let me know what you think, or if you have found a solution.
    Wassim
    <img src=/S/compute.gif border=0 alt=compute width=40 height=20> in the <img src=/S/bagged.gif border=0 alt=bagged width=22 height=22>

Posting Permissions

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