CN100432949C - Method and device for storing user data on computer when software crashing - Google Patents

Method and device for storing user data on computer when software crashing Download PDF

Info

Publication number
CN100432949C
CN100432949C CN 200510034443 CN200510034443A CN100432949C CN 100432949 C CN100432949 C CN 100432949C CN 200510034443 CN200510034443 CN 200510034443 CN 200510034443 A CN200510034443 A CN 200510034443A CN 100432949 C CN100432949 C CN 100432949C
Authority
CN
China
Prior art keywords
step
software
computer
automatic backup
user data
Prior art date
Application number
CN 200510034443
Other languages
Chinese (zh)
Other versions
CN1725187A (en
Inventor
里 万
段雨洛
章庆元
Original Assignee
珠海金山软件股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 珠海金山软件股份有限公司 filed Critical 珠海金山软件股份有限公司
Priority to CN 200510034443 priority Critical patent/CN100432949C/en
Publication of CN1725187A publication Critical patent/CN1725187A/en
Application granted granted Critical
Publication of CN100432949C publication Critical patent/CN100432949C/en

Links

Abstract

本发明公开了一种在计算机上当软件崩溃时保存用户数据的方法及装置,该方法及装置只在软件发生崩溃时对正在进行处理的数据进行保存,既能对数据进行充分保护,又节约计算机资源。 The present invention discloses a method and apparatus for user data in the computer when the software crashes, only the method and apparatus for processing data being saved in a software crash occurs, both to ensure an adequate protection, but also save the computer resources. 该方法是在所述的软件中包含检测步骤、自动备份步骤和显示提示信息步骤,检测步骤主动检测正在运行的被检测模块(应用程序)是否有崩溃发生,然后将软件崩溃的消息通知给自动备份步骤,自动备份步骤即对此时(崩溃发生时)的有效数据进行保存,显示信息步骤则显示出提示用户查看自动备份的文件的信息,当再次启动该应用程序时,用户可以使用这些文件快速恢复工作。 The notification message is included in the software in the detecting step, the step of automatic backup and display a message step, the step of detecting active detection module is running is detected (application) if there is a crash occurs and the software to automatically collapse backup step, i.e. the step of automatically backed up (time of the crash) at this time valid data is saved, the display information showing the step of the user to see the automatic backup file information, when the application is started again, the user can use these files rapid return to work. 本发明应用于计算机领域。 The present invention applies to the field of computers.

Description

在计算机上当软件崩溃时保存用户数据的方法及装置 The user data stored in the computer when the software crashes method and apparatus

技术领域 FIELD

本发明涉及一种在计算机上当软件崩溃时保护用户数据的方法及装置。 The present invention relates to a method and apparatus for protecting user data in the computer when the software crashes.

背景技术 Background technique

由于软件与操作系统的冲突、软件自身程序编制等各种原因,软件在运行时可能遇到各种错误,有些还会使得程序出现异常而不能继续运行,从而弹出操作系统级错误,或者是应用程序执行某一操作指令,用户在等待一段较长时间后,发现应用程序仍然在执行该操作指令,处于忙碌无响应状态, 但事实上应用程序仍然在运行,只是非常缓慢。 For various reasons conflicts software and operating systems, such as software programming itself, the software may encounter a variety of run-time errors, and some will make the program appear abnormal and can not continue to run, so the pop-up operating system-level error, or an application program to perform an operation instruction, after waiting for a long time and found that the application is still in the implementation of the operation instruction, is busy unresponsive state, but in fact the application is still running, but very slowly. 上述情况可以称为软件崩溃。 Above it may be referred to as software crashes. 一旦出现这些情况,用户不能再对软件进行操作,没有机会对当前的正在处理的内容进行保存,那么,尚未保存的数据就会丢失,从而给用户造成损失。 Once that happens, you can not operate the software, there is no chance of the content currently being processed to save, then the unsaved data will be lost, resulting in losses to the user. 目前,针对软件崩溃时数据的保护措施,主要采用定时备份的方法。 Currently, software crash protection for data, the main method timed backup. 定时备份是指,每隔一段指定时间,自动将程序中正在处理的数据备份存储到计算机可访问介质的指定路径下。 Backup refers to the timing, a specified time interval, to automatically back up data stored in the program being processed into a computer-accessible medium specified path. 这样, 一旦发生软件崩溃,在再次启动该软件时可以读取距软件崩溃的时间点最近一次的备份文件并提供给用户。 Thus, once the software crashes occur when starting the software again it can be read from a software crash point in time of the last backup file and made available to the user. 这种方法实现上比较简单,但存在着以下不足:第一,在指定的保存间隔时间中途发生软件崩溃,此时到上一次保存时刻中,用户进行的操作必然丢失;第二,每隔指定的保存间隔时间,程序都进行保存操作,这需要占用 This method is implemented on a simple, but there are the following disadvantages: First, a software crash occurs in the middle of the specified interval is stored, this time to the last saved time, the operation by the user inevitably lost; second, every predetermined save time interval, the program save operation, which take up

额外的计算机资源(如中央处理器、内存、以及磁盘空间等)。 Additional computer resources (such as CPU, memory, and disk space, etc.). 而且上述两点 And these two points

之间还存在这样的矛盾:即,如果指定的保存间隔时间设置的比较短,就会对计算机造成比较大的性能影响, 一定程度上浪费了用户的资源;如果指定的保存间隔时间设置的比较长,那么数据又不能得到充分的保护。 There is also a contradiction between: that is, if the specified save set relatively short time interval, the user will result in waste of resources, a relatively large impact performance, to a certain extent on the computer; save relatively if the specified time interval set long, then the data can not be fully protected.

发明内容本发明所要解决的技术问题是克服现有技术的不足,提供一种在计算机上当软件崩溃时保护用户数据的方法,该方法不需要定时保存数据,只在软件发生崩溃时对正在进行处理的用户数据进行保存,既能对用户数据进行充分保护,又节约计算机资源。 SUMMARY OF THE INVENTION The present invention is to overcome the shortcomings of the prior art, there is provided a method of protecting data when the user computer when the software crashes, the method does not require the timing of saving data being processed only when the software crashes user data is stored, both to the full protection of user data, but also save computer resources.

本发明所要解决的另一技术问题是,提供一种在计算机上当软件崩溃时 Another technical problem to be solved by the present invention is the time taken to provide a computer software crashes

保护用户数据的装置。 Protection device user data.

本发明在计算机上当软件崩溃时保存用户数据的方法采用的技术方案是:本发明所述计算机包括CPU和操作系统模块,所述的软件包括被检测模块,所述的软件还包含以下步骤: Aspect of the present invention to save the user data in the computer when the software crashes method is that: the computer of the present invention includes a CPU and an operating system module, the detection module includes software, the software further comprises the step of:

(1) 检测步骤; (1) detecting step;

(2) 自动备份步骤; (2) automatic backup step;

(3) 显示提示信息步骤; (3) display a message step;

所述检测步骤用于当所述被检测模块正在运行时,主动检测所述被检测模块是否有崩溃发生,如果检测到有崩溃发生,则进入所述自动备份步骤; Said detecting step is for, when the detection module is running, the active detection module detects whether there is a crash occurs, a crash occurs if there is detected, the process proceeds to the step automatic backup;

所述自动备份步骤用于检査计算机内存中正在被处理的用户数据,并将其中可识别的用户数据用自动备份文件的形式保存到计算机可访问介质的指定目录; The automatic backup step of checking for user data in computer memory is being processed, and wherein the identified user data is stored in the form of an automatic backup file to the specified directory in a computer-accessible medium;

所述显示提示信息步骤用于当发现所述计算机可访问介质上有所述自动备份步骤保存的自动备份文件时,显示信息以提示用户査看。 The message display step for, when found in the computer-accessible automatic backup files saved in said step of automatic backup medium, prompting the user to view the displayed information.

所述检测步骤采用监测进程与应用程序通讯的方法来检测所述被检测模块是否有崩溃发生; The detecting step process monitoring method of communication with the application to detect whether the detection module is crashes;

当所述被检测模块发生部分崩溃时,所述自动备份步骤采用调用应用程序二次开发接口方法或发送消息的方法通知所述被检测模块保存用户数据, 或者所述自动备份步骤通过共享计算机内存中用户数据的方法来进行恢复备份;当所述被检测模块发生整体崩溃时,所述自动备份步骤通过共享计算机内存中用户数据的方法来进行恢复备份;所述显示提示信息步骤采用立即显示或通知所述被检测模块在所述软件下次运行时显示的方法来显示提示信息。 When the detection module is part of a crash occurs, the step of using the automatic backup calling application method or secondary development interface method of sending a message notifying the user data is saved detection module, the automatic backup or shared computer memory by step user data to restore a backup method; occurs when the detection module is integrally crash, the automatic backup restore step is performed by a method for sharing a backup of user data in a computer memory; using the display step display a message immediately or the notification method of a display module is detected next run software to display the message.

本发明在计算机上当软件崩溃时保存用户数据的装置所采用的技术方案是:本发明所述软件包括被检测模块和所述保存用户数据的装置,该装置包括检测装置、自动备份装置和显示提示信息装置,所述检测装置用于当所述被检测模块正在运行时,主动检测所述被检测模块是否有崩溃发生,当检测到有崩溃发生时,通知所述自动备份装置,所述自动备份装置用于接到通知后将计算机内存中正在被编辑的可识别的用户数据用自动备份文件的形式保存到计算机可访问介质的指定目录,所述显示提示信息装置用于当发现所述计算机可访问介质上有所述自动备份装置保存的自动备份文件时,立即显示信息或通知被检测模块在软件下次运行时显示信息以提示用户査看。 Technical Solution The present invention to save the user data in the computer when the software crashes are used: the software of the present invention includes a detecting module and a user data storage device, the apparatus comprising detecting means, and automatic backup means prompts information means, said detecting means being for detecting when said module is running, the active detection module detects whether a crash is occurring, when there is detected a crash occurs, the automatic backup notification means, the automatic backup means for user data notified after the computer's memory that is being edited is stored in the form of recognizable automatic backup file to the specified directory computer-accessible medium, the message display means for, when said computer discovery accessible medium have the automatic backup file is saved when the automatic backup means immediately displaying information or notification information is displayed to prompt the user to view the software running the next detection module.

本发明的有益效果是:由于本发明在计算机上当软件崩溃时保存用户数据的方法是在所述的软件中包含检测步骤、自动备份步骤和显示提示信息步骤,检测步骤主动检测正在运行的被检测模块(应用程序)是否有崩溃发生, 然后将软件崩溃的消息通知给自动备份步骤,自动备份步骤即对此时(崩溃发生时)的有效数据进行保存,显示信息步骤则显示出提示用户査看自动备份的文件的信息,当再次启动该应用程序时,用户可以使用这些文件快速恢复工作,将软件崩溃带来的负面影响降低到最小,所以能在最大程度上保护用户尚未保存的数据资料,而且在程序的绝大部分正常运行时间中,不需要定时保护用户数据,不会过多地占用资源而影响计算机的性能。 Advantageous effects of the invention are: Since the present invention is a method to save the computer when the user data when the software crashes comprising the step of detecting in the software, automatic backup steps and prompts, step detecting step of actively detecting the running is detected module (application) whether a crash occurs, and then notifies the software crash automatic backup step, i.e. the step of automatically backed up (time of the crash) at that time to save user data, the information display step displays a user to see information files automatically backed up when the application is started again, the user can use these files to quickly return to work, the software crashes negative impact to a minimum, they are able to protect the user's data has not been saved to the maximum extent, and in most of the uptime program does not require time protection of user data, will not take up too much resources affect the computer's performance.

另外本发明还提供了一种在计算机上当软件崩溃时保存用户数据的装置,使得上述方法可以得到具体的实施。 The present invention also provides a device for the user data stored in the computer when the software crashes, such that the above-described method can be obtained in particular embodiments.

附图说明 BRIEF DESCRIPTION

图1是本发明在计算机上当软件崩溃时保存用户数据的方法的主流程示意图;图2是本发明在计算机上当软件崩溃时保存用户数据的方法的流程简 FIG 1 is a main flow for user data when the software crashes schematic process of the present invention taken in a computer; FIG. 2 is a flow profile of the present invention to save the user data in the computer when the software crashes method

图; Figure;

图3是本发明在计算机上当软件崩溃时保存用户数据的方法的流程示意 FIG 3 is a schematic flow when the user data stored in the computer when the present invention is a method of software crashes

图; Figure;

图4是本发明在计算机上当软件崩溃时保存用户数据的装置的结构示意图。 FIG 4 is a schematic structural diagram of a user data storage device according to the present invention when taken in computer software crash.

具体实施方式 Detailed ways

如图l、图2、图3所示,本发明在计算机上当软件崩溃时保存用户数据的方法中所述的计算机包括CPU和操作系统模块,所述的软件包括被检测模块,所述的软件还包含以下三个步骤: FIG method L, FIG. 2, as shown, the present invention is to save the user data 3 when the computer when the computer software crash includes a CPU and an operating system module, the detection module includes software, the software further comprising the following three steps:

(1)检测步骤:该步骤是当所述被检测模块正在运行时,主动检测所述被检测模块是否有崩溃发生,如果检测到有崩溃发生,则进入所述自动备份步骤。 (1) detecting step: This step is detected when said module is running, the active detection module detects whether a crash is occurring, if there is detected a crash occurs, the process proceeds to the step automatic backup.

检测步骤采用监测进程与应用程序通讯的方法来检测所述被检测模块是否有崩溃发生。 Process monitoring step detecting method of communication with the application to detect whether the detection module is a crash occurs.

所述监测进程与应用程序通讯的方法是启动一个监测程序,定时与应用程序通讯。 The method of communication with the application monitoring process is to start a monitoring process, and the timing of communication applications. 所述的通讯可以采用主动请求通讯,即所述的通讯的步骤是先由监测程序主动向应用程序发出请求,再由应用程序给出响应,表明当前运行状况良好,并可以告知响应的内部数据情况,用于出现异常情况时进行数据的备份。 The internal data communication correspond actively request step, i.e., the communication may be employed first by monitoring actively sends a request to the application program, then the response given by the application, that the current running in good condition, and the response may inform when the backup data, the abnormal situation occurs for. 当监测程序在一定时间间隔内没有收到通知时,就可以确定应用程序出现了异常情况,进入自动备份步骤; When the monitoring procedure is not notified within a certain time interval, the application can determine the abnormal condition occurred, step into the automatic backup;

所述的通讯也可以采用被动响应通讯,由应用程序主动通知监测程序, 表明当前运行状况良好,并可以告知响应的内部数据情况,用于出现异常情况时进行数据的备份。 The communication may be passive response communication, proactive notification by the application monitoring process, that the current running in good condition, and may inform the internal data in response to the situation, when abnormal situation for the backup data. 当监测程序在一定时间间隔内没有收到通知时,就可以确定应用程序出现了异常情况,进入自动备份步骤。 When the monitoring program does not receive notification within a certain time period, you can determine the application appeared abnormal situation, into the automatic backup procedure. 本发明所述检测步骤同样可以检测响应常见的系统异常。 The present invention may also be detected in response to the step of detecting the common system abnormalities. 系统异常是指发生了意外或是使进程不能正常进行的事件,可以分为硬件和软件两种,例如:访问一个尚未提交的页会引起硬件异常,而一个无效的参数或者被0除会引起软件异常。 Refers to abnormal system had an accident or the course of events can not be normal, and can be divided into both hardware and software, such as: access to a page not yet submitted will cause a hardware exception, but an invalid argument or division by zero will cause software exception. 不管是硬件异常还是软件异常可引起软件(正在运行的被检测模块)崩溃。 Whether hardware or software anomaly can cause abnormal software (running the detection module) crash.

(2)自动备份步骤,该步骤接收到所述检测步骤传输的软件崩溃信息时, 检査计算机内存中正在被处理的用户数据,并将其中可识别的用户数据用易识别的自动备份文件的形式保存到计算机可访问介质的指定目录。 (2) automatic backup step of receiving the user data transmission detecting step when the software crash information, check the computer's memory that is being processed, and wherein the identified user data automatically back up files easily identified save the form to the specified directory on the computer-accessible media.

当所述被检测模块发生部分崩溃时,自动备份步骤可采取调用应用程序二次开发接口的方法来通知被检测模块进行数据保存。 When the detection module is part of a crash occurs, the automatic backup procedure may take the calling application secondary development interface to notify the data to be saved detection module.

二次开发接口是应用程序以函数、接口等形式提供的一组功能,可以被应用程序本身或应用程序之外的其他程序、脚本等使用。 Secondary development interface is a set of functions provided in the form of application functions, interface, etc., can be used by a program other than the application itself, or the application scripts. 一般而言,这组功能是应用程序已经实现的。 In general, this set of functions is an application that has been achieved. 其它应用程序在这组功能的基础上,可以实现更多的应用功能。 Other applications on the basis of this group of functions, can achieve more applications.

在软件捕获到异常时,在异常处理中就可以调用保存文件一类的方法将当前应用程序中的所有文档保存下来。 When the software is to capture an exception, exception handling can call to save the file in a class method to save all documents in the current application down.

如果软件本身没有提供二次开发接口,可以将内部的保存文件方法导出, 以供异常处理代码使用。 If the software itself does not provide secondary development interface, internal methods for saving files can be exported for use exception handling code. 如使用下列代码- The following code -

〃已捕捉到异常后 After 〃 has caught an exception

int nDocs = m_pDocs->GetCount 0; while (nDocs—) int nDocs = m_pDocs-> GetCount 0; while (nDocs-)

if (m_pDocs_>IsDirty()) if (m_pDocs_> IsDirty ())

mjpDocs-〉GetDoc(nDocs)->Save();除了上述调用程序二次开发接口的方法,还可以采用发送消息的方式通知被检测模块保存用户数据: mjpDocs-> GetDoc (nDocs) -> Save (); the above-described embodiment except that the caller method of secondary development interface, may also be used to send a message notifying the user data is stored detection module:

消息机制是现代操作系统的典型特征,如Windows就是采用消息机制的事件驱动型的操作系统。 Message mechanism is typical of modern operating systems such as Windows message mechanism is the use of event-driven operating system. 在Windows环境中,应用程序与应用程序之间、应用程序与操作系统之间、各类驱动程序之间都是通过消息来进行通信的。 In a Windows environment, between the application and the application between the application and the operating system, among various types of drivers are used to communicate through messages. 通常这些消息是输入设备产生的事件,如窗体、键盘、鼠标事件。 These messages are typically generated by an input device event, such as a form, a keyboard, a mouse event.

对于常见的Windows操作系统,整个系统是一个系统消息队列。 For common Windows operating system, the entire system is a system message queue. 系统通过应用程序来检索该消息队列,把控制权交给其他任务,并允许该任务以协作方式运行起来。 Through the application system to retrieve the message queue, give control to other tasks, and allow the mission up and running in a cooperative manner. 如果某一应用程序检索消息失败,或者没有按照系统规则査看消息队列,从而阻止了其他应用程序对消息队列的检索,那么,系统就会把其他应用程序挂起,直到出错的应用程序结束。 If an application fails to retrieve the message, or did not see the message queue in accordance with the rules of the system, thus preventing other applications to retrieve the message queue, then the system will bring another application to hang until the end of the application error.

所以在检测到异常发生时可以通过给Windows Api PostMessage来给出现异常的线程发送消息,以通知应用程序进行数据备份。 Therefore, when an abnormality is detected by the occurrence of thread sends a message to the Windows Api PostMessage to be abnormal, and to notify the application for data backup. 这种方法适合监测程序能够提前发现外部系统异常的情况。 This method is suitable for monitoring the programs to an external system abnormality is found in advance. 以下是一个典型的以消息处理为中心的示例程序代码片断: 〃一、消息处理函数 The following is a typical message processing center to the examples of program code snippet: 〃 a message handler

〃参数:窗口句柄,消息,消息参数,消息参数 〃 parameters: the window handle, a message, a message parameter, a message parameter

LRESULT CALLBACK WndProc(HWND hwnd, UINT message, WPARAM wParam, LPA應lPa屋) LRESULT CALLBACK WndProc (HWND hwnd, UINT message, WPARAM wParam, LPA should lPa house)

〃处理感兴趣的消息 〃 process messages of interest

case WM—DESTROY: case WM-DESTROY:

〃当用户关闭窗口,窗口销毁,程序需结束,发退出消息,以退出消息循环 〃 When the user closes the window, the window is destroyed, to be the end of the program, send exit message, the message loop to exit

PostQuitMessage (0); return 0 ; PostQuitMessage (0); return 0;

〃其他消息交给由系统提供的缺省处理函数 〃 message to other functions provided by the default processing system

return : :DefWindowProc (hwnd, message, wPaxam, lPaxam); return:: DefWindowProc (hwnd, message, wPaxam, lPaxam);

〃二、应用程序主函数 〃 Second, the application's main function

int WINAPI WinMain (HINSTANCE hlnstance, HINSTANCE hPrevInstance, int WINAPI WinMain (HINSTANCE hlnstance, HINSTANCE hPrevInstance,

PSTR szCmdLine, int iCmdShow) PSTR szCmdLine, int iCmdShow)

〃消息循环 〃 message loop

MSG msg ; MSG msg;

while (GetMessage (&msg, NULL, 0, O)) 〃从消息队列中取消息 while (GetMessage (& msg, NULL, 0, O)) 〃 taking messages from the message queue

Trans 1 ateMessage (&msg); 〃转换消息DispatchMessage (&msg); 〃派发消息 Trans 1 ateMessage (& msg); 〃 converted message DispatchMessage (& msg); dispatch message 〃

return msg-wParam ; return msg-wParam;

上述两种方法在实际应用中比较常见,除此之外还可以通过共享计算机内存中用户数据的方法,由自动备份装置根据内存映象来恢复用户数据,以达到备份用户数据的目的。 Comparison of the two methods common in practical applications, in addition also by the automatic backup means to recover the user data according to a memory map shared by the process of user data in the computer's memory, to achieve the purpose of backup user data. 而当被检测模块发生整体崩溃时,自动备份步骤就只能通过共享计算机内存中用户数据的方法,由自动备份装置根据内存映象来恢复用户数据。 When the entire module is detected a crash occurs, only through the step of automatic backup method for sharing user data in the computer's memory, the automatic backup means to restore the user data based on the memory map.

不管是应用何种方法,为了应用程序在重新启动时还能够提示用户恢复文件,在备份数据的同时还需要在一个特定的地方写入额外信息,如在系统注册表或者应用程序的配置文件中写入备份数据信息,可以是出现异常数据的时间,也可以是原文件名,或者是两者的组合。 Whatever the method of application, in order to restart the application Shihai can prompt the user to restore files, you need to write additional information in a particular place at the same time backing up data, such as configuration file in the system registry or application write backup data, the time may be abnormal data occurs, it can be the original file name, or a combination of both. 其目的是为了能让用户根据信息很容易识别其对应的原始数据。 Its purpose is to allow the user to easily recognize the corresponding original data based on the information. 举例如下:首先是对正在编辑的文件进行遍历,调用API检査文件是否需要保存,如果不需要保存,则直接检査下一个文件,否则,以"原文件名+当前系统时间"的规则生成一个新文件名,保存到指定目录(重新命名是因为将未保存文件都保存在一个路径下, 避免文件重名),遍历完成,保存也就完成了。 For example as follows: First is the file being edited is traversed API call to check whether a file needs to be saved, if not save, then directly check the next file, otherwise, "the original file name + the current system time" rule to generate a a new file name, saved in the specified directory (re-named because unsaved files are saved in a path, avoid file the same name), traversal is complete, save it done.

当所述自动备份步骤完成后,进入下述显示信息步骤。 When the automatic backup step is completed, the display information into the following step.

(3)显示提示信息步骤,该步骤用于当发现所述计算机可访问介质上有所述自动备份步骤保存的自动备份文件时,采用立即显示的方法或通知被检测模块在下次启动时显示的方法来显示提示用户指定路径下有自动备份文件的数据信息,使用户知晓目前有自动备份的文件,从而在用户再次启动应用程序时可以从计算机可访问介质上査看这些自动备份文件。 (3) the step of displaying message, the discovery step for, when the computer-accessible automatic backup file is automatically saved to the backup media on a step, or a method of using the notification module is displayed immediately displayed at the next start detector there are ways to display data automatically back up files prompt the user to specify the path, so that the user knows there are files automatically backed up, so that when the user starts the application again can be accessed from a computer on the media to view these files automatically backed up.

显示信息可以采用多种手段,如可以用对话框、系统提供的屏幕提示、 声音提示等方法。 Display information may use a variety of means, such as a dialog box can be used, the system provides screen prompts, voice prompts or the like.

对话框是图形用户界面(GUI)用于进行人机交互最常见的方法之一,它可设计为一个模态对话框,用户可以阅读上面的文字,内容可以包括目前程序遇到的错误,说明已经将用户正在编辑的文件保存到一个指定的计算机可访问介质的文件路径下,这样,用户即明确知晓了自动备份文件的存在并可以前往该文件路径下査看这些自动备份文件。 Dialog is a graphical user interface (GUI) for one of the most common methods of human-computer interaction, it can be designed for a modal dialog box, users can read the text above, the content may include the current program encounters an error, indicating under the user has saved the file being edited to a specified computer-accessible medium file path, so that the user that is clearly aware of the existence of an automatic backup of files and can go down the path to view these files automatically backup files. 如图4所示,对应于上述方法的在计算机上当软件崩溃时保存用户数据的装置,所述软件包括被检测模块和所述装置,所述装置包括检测装置、自动备份装置和显示提示信息装置,所述检测装置用于当所述被检测模块正在运行时,用主动请求通讯检测或被动响应通讯检测的方式检测所述被检测模块是否有崩溃发生,当检测到有崩溃发生时,则通知所述自动备份装置进行自动备份;自动备份装置便采用调用二次开发接口的方法或发送消息的方法, 通知被检测模块对正在编辑的用户数据进行保存,或者根据内存映象自动保存的方法来由自动备份装置对正在编辑的用户数据进行保存;显示提示信息装置不时对自动备份装置进行访问,当发现自动备份装置有备份用户数据时, 采用立即显示的方式或通知被检测模块在下次启动时显示的方式显示出提示用户査 4, the device user data corresponds to the above methods when the computer when stored software crashes, said software module comprising detecting and said means, said means comprising means prompt information detecting means, display means and automatic backup a detecting means for detecting when said module is running, the communication request is detected active manner or a passive response to communication detected by the detecting module detects whether a crash occurs, when there is detected a crash occurs, the notification the automatic backup automatic backup means; automatic backup means they use to call methods or secondary development interface method of transmitting a message notifying the detection module is being edited user data to save, or according to a method of automatically saved memory image the user data being edited is saved by the automatic backup means; display message device from time to time for automatic backup means accesses, when found in automatic backup means has backup user data, using the time mode or the notification displayed immediately is stored in the next startup detection module the show displayed prompting the user to check 自动备份文件的信息。 Information files automatically backed up.

本发明通过上述实施例的步骤和装置,将处理程序非法操作和用户数据保护融合起来,在最大程度上保护了用户尚未保存的数据资料;保存工作完成后及时通知用户,便于用户査看文件以继续操作。 By means of the present invention and steps of the above-described embodiment, the processing program illegal operation and integrate user data protection, protection of the user data has not been saved to the maximum extent; notify a user after the completion of saving, easy for users to view the file continue.

Claims (3)

1、一种在计算机上当软件崩溃时保存用户数据的方法,所述计算机包括CPU和操作系统模块,所述的软件包括被检测模块,其特征在于,在所述的软件中还包含有以下步骤: (1)检测步骤; (2)自动备份步骤; (3)显示提示信息步骤; 所述检测步骤用于当所述被检测模块正在运行时,主动检测所述被检测模块是否有崩溃发生,如果检测到有崩溃发生,则进入所述自动备份步骤; 所述自动备份步骤用于检查计算机内存中正在被处理的用户数据,并将其中可识别的用户数据用自动备份文件的形式保存到计算机可访问介质的指定目录; 所述显示提示信息步骤用于当发现所述计算机可访问介质上有所述自动备份步骤保存的自动备份文件时,显示信息以提示用户查看。 A user data stored in the computer when the software crashes, said computer comprising a CPU and an operating system module, a detection module comprises software, wherein the software further comprises the steps of : (1) detecting step; (2) automatic backup step; (3) the step of displaying prompt information; the step of detecting when said module is running is detected, the active detection module detects whether there is a crash occurs, If it is detected that there is a crash occurs, the process proceeds to the step automatic backup; automatic backup said step of checking for user data in computer memory is being processed, and wherein the identified user data is stored in the form of a computer to automatically back up files specify a directory accessible medium; and when the step of displaying a message when the computer-accessible discovery automatic backup files saved in said step of automatic backup medium, prompting the user to view the displayed information.
2、 根据权利要求1所述的在计算机上当软件崩溃时保护用户数据的方法, 其特征在于,所述检测步骤采用监测进程与应用程序通讯的方法来检测所述被检测模块是否有崩溃发生;当所述被检测模块发生部分崩溃时,所述自动备份步骤采用调用应用程序二次开发接口方法或发送消息的方法通知所述被检测模块保存用户数据,或者所述自动备份步骤通过共享计算机内存中的用户数据的方法来进行恢复备份;当所述被检测模块发生整体崩溃时,所述自动备份步骤通过共享计算机内存中的用户数据的方法来进行恢复备份; 所述显示提示信息步骤采用立即显示或通知所述被检测模块在所述软件下次运行时显示的方法来显示提示信息。 2, to protect user data in the computer when the software crashes method according to claim 1, wherein the detecting step uses a method of monitoring a process of communication with the application to detect whether the detection module is crashes; when the detection module is part of a crash occurs, the step of using the automatic backup calling application method or secondary development interface method of sending a message notifying the user data is saved detection module, the automatic backup or shared computer memory by step the method of the user data to restore a backup; occurs when the detection module is integrally crash, the automatic backup restore step is performed by means of the backup computer memory shared user data; using the display message immediately step or notifying the detected display module to display a message in the display method of operation of the software next time.
3、 一种在计算机上当软件崩溃时保存用户数据的装置,所述软件包括被检测模块,其特征在于:所述软件还包含所述装置,所述装置包括检测装置、自动备份装置和显示提示信息装置,所述检测装置用于当所述被检测模块正在运行时,主动检测所述被检测模块是否有崩溃发生,当检测到有崩溃发生时,通知所述自动备份装置,所述自动备份装置用于接到通知后将计算机内存中正在被处理的可识别的用户数据用自动备份文件的形式保存到计算机可访问介质的指定目录,所述显示提示信息装置用于当发现所述计算机可访问介质上有所述自动备份装置保存的自动备份文件时,立即显示信息或通知被检测模块在软件下次运行时显示信息以提示用户査看。 3. A device user data stored at the computer when the software crashes, said software comprising a detection module, wherein: said software means further comprising, said means comprising a detecting means, and automatic backup means prompts information means, said detecting means being for detecting when said module is running, the active detection module detects whether a crash is occurring, when there is detected a crash occurs, the automatic backup notification means, the automatic backup means for receiving user data may identify the computer's memory after the notification being processed is stored in the form of an automatic backup file to the specified directory computer-accessible medium, the message display means for, when said computer discovery accessible medium have the automatic backup file is saved when the automatic backup means immediately displaying information or notification information is displayed to prompt the user to view the software running the next detection module.
CN 200510034443 2005-04-30 2005-04-30 Method and device for storing user data on computer when software crashing CN100432949C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN 200510034443 CN100432949C (en) 2005-04-30 2005-04-30 Method and device for storing user data on computer when software crashing

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN 200510034443 CN100432949C (en) 2005-04-30 2005-04-30 Method and device for storing user data on computer when software crashing

Publications (2)

Publication Number Publication Date
CN1725187A CN1725187A (en) 2006-01-25
CN100432949C true CN100432949C (en) 2008-11-12

Family

ID=35924669

Family Applications (1)

Application Number Title Priority Date Filing Date
CN 200510034443 CN100432949C (en) 2005-04-30 2005-04-30 Method and device for storing user data on computer when software crashing

Country Status (1)

Country Link
CN (1) CN100432949C (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104714861A (en) * 2013-12-16 2015-06-17 阿里巴巴集团控股有限公司 Scene recovery data saving method and application running method, device and system

Families Citing this family (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100504899C (en) 2006-08-29 2009-06-24 联想(北京)有限公司 Software watchdog system and method
CN101373450B (en) 2007-08-21 2010-09-29 联想(北京)有限公司 Method and system for processing CPU abnormity
CN102033823B (en) * 2009-09-27 2014-03-19 中兴通讯股份有限公司 Method and device for storing data
CN102262571B (en) * 2011-07-25 2013-01-30 福建星网锐捷网络有限公司 Method, device and equipment for processing system crash
CN103279393B (en) * 2012-10-17 2016-05-04 厦门雅迅网络股份有限公司 Navigator application based method of crash-proof plug-in memory card
CN102929761B (en) * 2012-11-16 2015-10-28 赛尔网络有限公司 One kind of system crashes and error method to deal with
CN103870356B (en) * 2012-12-11 2017-12-01 联想(北京)有限公司 An information processing method and an electronic device
CN103678091A (en) * 2013-12-19 2014-03-26 北京奇虎科技有限公司 Method and device for processing crash data of application software
CN104978352B (en) * 2014-04-10 2019-05-24 腾讯科技(深圳)有限公司 The method and client of information processing
CN105320615A (en) * 2014-07-30 2016-02-10 宇龙计算机通信科技(深圳)有限公司 The method of data storage and data storage means
CN105512008B (en) * 2014-09-22 2018-05-11 华为技术有限公司 A method of acquiring failure information method and apparatus
CN105718791A (en) * 2014-12-01 2016-06-29 Tcl集团股份有限公司 Method and apparatus for protecting application program data
CN104915603A (en) * 2015-04-30 2015-09-16 努比亚技术有限公司 Terminal equipment data storage method and terminal equipment
CN106446700A (en) * 2016-10-20 2017-02-22 上海理工大学 Automatic file saving method achieving power failure preventing

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020194528A1 (en) 2001-05-22 2002-12-19 Nigel Hart Method, disaster recovery record, back-up apparatus and RAID array controller for use in restoring a configuration of a RAID device
US6701454B1 (en) 2000-06-05 2004-03-02 Microsoft Corporation Method and system for recovering information during a program failure
US6816984B1 (en) 2000-06-23 2004-11-09 Microsoft Corporation Method and system for verifying and storing documents during a program failure

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6701454B1 (en) 2000-06-05 2004-03-02 Microsoft Corporation Method and system for recovering information during a program failure
US6816984B1 (en) 2000-06-23 2004-11-09 Microsoft Corporation Method and system for verifying and storing documents during a program failure
US20020194528A1 (en) 2001-05-22 2002-12-19 Nigel Hart Method, disaster recovery record, back-up apparatus and RAID array controller for use in restoring a configuration of a RAID device

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104714861A (en) * 2013-12-16 2015-06-17 阿里巴巴集团控股有限公司 Scene recovery data saving method and application running method, device and system

Also Published As

Publication number Publication date
CN1725187A (en) 2006-01-25

Similar Documents

Publication Publication Date Title
EP1137987B1 (en) Initializing and restarting operating systems
JP4942932B2 (en) System and method for providing access to the user interface information
JP3079079B2 (en) Screen display device and a screen display control method
US6126328A (en) Controlled execution of partitioned code
US7225361B2 (en) Detecting a stalled routine
US6622260B1 (en) System abstraction layer, processor abstraction layer, and operating system error handling
US8965929B2 (en) Manipulating electronic backups
US7409536B2 (en) Computer systems with several operating systems coexisting thereon and swapping between these operating systems
US6643802B1 (en) Coordinated multinode dump collection in response to a fault
Russinovich et al. Windows internals
CN101213518B (en) System and method to optimize OS context switching by instruction group trapping
JP5925803B2 (en) Prediction of failure of the application based on the resource access patterns, diagnosis, and recovery from failure
US8448165B1 (en) System and method for logging operations of virtual machines
US6418542B1 (en) Critical signal thread
US7028056B1 (en) Method and arrangements for generating debugging information following software failures
US7574627B2 (en) Memory dump method, memory dump program and computer system
US20070277127A1 (en) Screensaver for individual application programs
CN100440157C (en) Detecting correctable errors and logging information relating to their location in memory
US6438709B2 (en) Method for recovering from computer system lockup condition
CN101884029B (en) Multithreaded processor with lock indicator
US6948094B2 (en) Method of correcting a machine check error
JP5225391B2 (en) Using the file system interface, method and apparatus for event notification mechanism of the operating system
US7293251B2 (en) Initiating and debugging a process in a high assurance execution environment
JP4459290B2 (en) Fast start-up from the stop state of the operating system
KR101512252B1 (en) Method of provisioning firmware in an operating system (os) absent services environment

Legal Events

Date Code Title Description
C06 Publication
C10 Request of examination as to substance
C14 Granted
C56 Change in the name or address of the patentee

Owner name: ZHUHAI KINGSOFT SOFTWARE CO., LTD.

Free format text: FORMER NAME: ZHUHAI JINSHAN SOFTWARE CO. LTD.