Page 1 of 3 123 LastLast
Results 1 to 15 of 33
  1. #1
    Join Date
    May 2008
    Posts
    13

    Unanswered: Good times with crashing MDE

    Howdy!
    The MDB works, but the MDE crashes in a few spots. This is loads of fun because it used to work...now it doesn't!

    This is in use in an office with everyone on 2007. App was leftover from the previous dude and naturally...no documentation. such is life.

    I've checked the references and few other little things i've found on the boards. Put I'm lost here.

    When I step in to debug, Studio doesn't let that happen. Know this error?
    Unhandled exception at 0x03160ec4 in MSACCESS.EXE: 0xC0000005: Access violation reading location 0xc403160e.
    Google doesn't

  2. #2
    Join Date
    Dec 2004
    Location
    Madison, WI
    Posts
    3,926
    Does the mde crash on other machines? The error sounds like the need to re-install MSAccess or something like malware, spyware, or a possible virus problem but I'd be curious if the mde crashes in a consistent spot. Have you run a system check? I've seen an error similar to this using a class module once which disappeared after removing the module.

    If you want to upload the mde/mdb (removing confidential info), I'd be happy to test it out on my machine.

    Otherwise, can you post what the code is or where it specifically is crashing (is it consistent in one spot?).
    Last edited by pkstormy; 05-09-08 at 15:06.
    Expert Database Programming
    MSAccess since 1.0, SQL Server since 6.5, Visual Basic (5.0, 6.0)

  3. #3
    Join Date
    May 2008
    Posts
    13
    It happens on multiple machines and always crashes in one place. I've had one reports of it crashing in a different place.

    I don't believe any 'ware is the problem. We're on a well protected LAN with solid protection.

  4. #4
    Join Date
    Dec 2004
    Location
    Madison, WI
    Posts
    3,926
    I guess the only question that remains is what is the code behind where it's crashing. Is it calling a module? Have you tried re-creating the form that the code crashes on? It might be a setting on the property of the form which Access doesn't quite like with the code. A lot of times, re-creating the form helps and solves problems like these.
    Expert Database Programming
    MSAccess since 1.0, SQL Server since 6.5, Visual Basic (5.0, 6.0)

  5. #5
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    Does the .MDB crash in the same place too? If not, I'd be suspecting corruption. Create a new database and import all your objects into it.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  6. #6
    Join Date
    May 2008
    Posts
    13
    Thank you for your suggestions, here's a progress [or lack thereof] update.
    I created a new mdb backend which contains all the data and imported the old stuff -- still crashed.
    Office ran diagnostics, found one problem -- still crashed.
    The mdb and mde both crash at the same point...what do you think, StarTrekker?
    I will look at re-creating the form. I'm a novice and this is one of those things that'll take me quite some time to redo...so I'm trying everything else first

    Thanks for all of your input!~

  7. #7
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    Try re-creating the front end by creating a new database and import all the objects?

    It still sounds like corruption to me...

    I'd now ask you questions like pkstormy did, so have another look at his post and see if you can give some feedback on that.

    When is it crashing? On opening a form or clicking a button...
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  8. #8
    Join Date
    May 2008
    Posts
    13
    Thanks StarTrekker...here's the latest.
    It crashes when I hit the exit button. It calls this function, but hates the red line:

    Private Sub Command60_Click()

    [Forms]![frmentry].ReLoad

    DoCmd.Close
    End Sub

    Is there something new with 2007 that doesn't care for this VB syntax? The only thing that should happen is to load the main page of the system.

  9. #9
    Join Date
    May 2008
    Posts
    13
    More info. This is a problem with the Close button.
    I've used the control wizard to create a new close button. This also causes the mdb to crash.

    good times.

  10. #10
    Join Date
    Dec 2004
    Location
    Madison, WI
    Posts
    3,926
    [Forms]![frmentry].ReLoad??? (or do you mean me.requery where you're trying to requery the underlying records again.)

    What are you trying to do with this command? I'm worried that you might have other commands like this on this or other forms which might be causing problems after seeing a command like this (which I'm guessing the mde has tried to ignore and crashed on.) Especially because I don't think there is such a command as ReLoad that exists in vba context (at least not one I've seen or used in many years of vba - but I do recall a ReLoad command in another language which I can't recall at the moment - might have been dbase - buttt...maybe it's a new 2007 MSAccess command). Are you sure you've run a Compile (Debug->Compile) on the code? (not a compact and repair!) If so, unless ReLoad is calling a module of some sort, you should get an error on this line (but maybe not since it's Forms!frmEntry.ReLoad - WATCH OUT for any commands which start out as Forms!FormSomething.... as these can make it past the compile process and still cause problems.) I'm guessing you have more questionable commands (such as Forms!SomeForm.SomeComand, etc...) that may be on one or more other forms which are causing problems. (Note: type the command in lower caps, if it doesn't capitolize, check the MSAccess help on the command to see if it's even a command. You can also try: me.somecommand to see if it's recognized versus using Forms!SomeForm.somecommand.)

    Otherwise...
    1. Try creating the form from scratch (a new mdb with ONLY this new form and your tables/queries and any needed macros/modules). Don't import any unnecessary queries or other code. Does this form require a subform? If so, create any subforms from scratch. You can do this quickly and don't worry about writing a bunch of code or making the form look exactly like the old form. You just want to make sure there's not another underlying problem such as table corruption, bad queries, or a module causing problems.
    2. Don't add any code which is questionable or doesn't compile! (Stay away from Forms!SomeForm.SomeCommand for the time being.)
    2. Make sure to Debug->Compile your code (don't be afraid to hit the Compile a few times and especially after any new code is added - it takes only a few seconds to compile.) (I will often Debug-Compile as well as Compact and Repair an mdb several times just to be sure.)
    3. Then, once it compiles without errors, test the mdb out. Create an mde and test that.
    4. If it works ok, then start adding the other forms. Again, watch for commands such as ReLoad which are not listed in the MSAccess help and don't compile. Remove or comment out any commands which don't compile.

    If you get a chance, upload your mdb. I'd be very interested in seeing what other commands like Forms!frmEntry.ReLoad you might have - especially ones like Forms!frmSomething..... From the experience everyone here has, we can quickly spot problem areas and make recommendations which will prevent your mdb from crashing.

    Quick question: How many other of these commands like Forms!SomeForm.SomeCommand do you have throughout the mdb? Can you possibly do a search for Forms! and see what other ones you have and list them in your next post.
    Last edited by pkstormy; 05-13-08 at 00:55.
    Expert Database Programming
    MSAccess since 1.0, SQL Server since 6.5, Visual Basic (5.0, 6.0)

  11. #11
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    Did you try to re-create the database (front end) by importing everything into a new db?

    I also don't recognise what you are trying to do with [Forms]![frmentry].ReLoad on an exit button.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  12. #12
    Join Date
    Sep 2007
    Location
    Global Village
    Posts
    185
    Just FYI There isn't any RELOAD in VBA even in 2007 edition and cause error when I put me.form.reload in a form for test
    I found a reload statement in Access Help which is for reloading XML Schema from a file.
    maybe if you remove the reload line from your entire code your problem would be fixed.
    <<Never Walk on the Traveled Path, Because it only Leads you to where the Others have been.>>
    Graham Bell

  13. #13
    Join Date
    Dec 2004
    Location
    Madison, WI
    Posts
    3,926
    I'm still betting he has some other commands similar to Forms!SomeForm.CommandX which are causing the problem. Just a hunch since he said he recreated the control and it didn't work but he didn't specify if he added the Forms!frmEntry.ReLoad command back into the code (sounded like he didn't). If he didn't, I'm guessing then that there's some other code like it unless he's removed it everywhere else which you're thinking Aran1.

    Thanks for the info Aran1 on the reload command and 2007. I couldn't find the reload command anywhere in the help for 2002.

    lootyman - any chance you could remove the confidential info and possibly zip the mdb and upload it? I'd really be interested in helping you troubleshoot it. I promise not to critique anything you've done other than to make some recommendations.
    Last edited by pkstormy; 05-13-08 at 06:09.
    Expert Database Programming
    MSAccess since 1.0, SQL Server since 6.5, Visual Basic (5.0, 6.0)

  14. #14
    Join Date
    Sep 2007
    Location
    Global Village
    Posts
    185
    I wonder how the code works without debugging. cuz code first shall be debugged and then executed which consequently raise an error for that reload statement
    <<Never Walk on the Traveled Path, Because it only Leads you to where the Others have been.>>
    Graham Bell

  15. #15
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    Good point. This is why I tend to think this is corruption of some kind.

    Maybe /DECOMPILE might help too.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

Posting Permissions

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