如何诊断MS接入崩溃 [英] How to diagnose MS access crashes

查看:203
本文介绍了如何诊断MS接入崩溃的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们已经写在Access中,有奇怪的崩溃中有一个自定义程序。我们增加了错误处理的记录和电子邮件这种情况发生我们自己的code内,已使我们能够解决我们所产生的大部分错误,但有时会发生崩溃我们code以外的任何崩溃。

We have a custom program written in Access that has odd crashes in it. We have added error handling that records and emails any crashes that happen inside of our own code and that has allowed us to fix most errors that we have generated, but sometimes the crashes happen outside of our code.

一说,我们发现其中出现了新的在2013年的一个例子 - 我们有编辑数据后会崩溃在某一个领域的一种形式 - 新的项目被罚款,但被创造将导致在记录之后的任何修改全面崩溃和MS访问关机。我们花了时间,最终找到了那我们的一些code的强制形式的移动到下一个记录,这个字段是该行的最后一个字段,但这样访问本身也正在尝试移动到下一个记录。自2007年以来这已经在系统中,但造成启动停产程序在2013年

An example of one that we found that cropped up new in 2013 -- we have a form that would crash after editing data in a certain field -- new entry was fine but any edits after the record was created would result in a full crash and shutdown of MS Access. We spent time and eventually tracked down that some code of ours was forcing the form to move to the next record, this field was the final field on the row though so Access itself was also attempting to move to the next record. This had been in the system since 2007, but started causing program shutdowns in 2013.

有没有什么办法来捕获和诊断内部MS接入方案级别崩溃?
Windows事件查看器只显示以下内容:

is there any way to trap and diagnose program level crashes inside MS access?
The windows event viewer only shows the following:

错误应用程序名称:MSACCESS.EXE,版本:15.0.4454.1501,时间戳:0x50a35ef4 错误模块名称:MSACCESS.EXE,版本:15.0.4454.1501,时间戳:0x50a35ef4 异常code:0000005 故障偏移:0x00116452 出错进程ID:0x1398 错误的应用程序启动时间:0x01ce6e665043d8be 错误的应用程序路径:C:\ Program Files文件(x86)的\的Microsoft Office \ Office15 \ MSACCESS.EXE 错误模块路径:C:\ Program Files文件(x86)的\的Microsoft Office \ Office15 \ MSACCESS.EXE 报告编号:6cfcb0eb-da62-11e2-8966-842b2b86f028

Faulting application name: MSACCESS.EXE, version: 15.0.4454.1501, time stamp: 0x50a35ef4 Faulting module name: MSACCESS.EXE, version: 15.0.4454.1501, time stamp: 0x50a35ef4 Exception code: 0xc0000005 Fault offset: 0x00116452 Faulting process id: 0x1398 Faulting application start time: 0x01ce6e665043d8be Faulting application path: C:\Program Files (x86)\Microsoft Office\Office15\MSACCESS.EXE Faulting module path: C:\Program Files (x86)\Microsoft Office\Office15\MSACCESS.EXE Report Id: 6cfcb0eb-da62-11e2-8966-842b2b86f028

推荐答案

在每一个访问数据库的每一个表单上每一个功能应该有一个流程,如下所示:

Every single function on every single form in every single Access database should have a flow that looks like this:

Private Sub btnMyButton_Click()
Dim MyVar as String
On Error GoTo ErrorHappened

'Do some stuff here...

ExitNow:
    Exit Sub

ErrorHappened:
    MsgBox Err.Description
    Resume ExitNow
End Sub

在ErrorHappened部分,你可以把它写你的表跟踪的bug。如果你改变你所有的替补与功能流这样,你应该能够捕获每一个问题,你的数据库了。也许写出来的Err.Number的和Err.Description它将。

In the ErrorHappened section, you can have it write to your table that tracks bugs. If you change all of your Subs and Functions to flow like this, you should be able to trap every single issue your database has. Maybe write out the Err.Number as well as Err.Description.

这篇关于如何诊断MS接入崩溃的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆