当前位置: 主页 > 论文指导 > 文献综述 >


时间:2010-10-07 00:06来源:三七论文网 作者:admin 我要投稿
什么是Delphi中的存取违规 What Delphi access violations are Your application will be shut down! ? XML :namespace prefix = o ns = urn:schemas-microsoft-com: Office :office / Access Violation, General Protection Fault or Invalid Page Fault, t



What Delphi access violations are
Your application will be shut down!<?XML:namespace prefix = o ns = "urn:schemas-microsoft-com:Office:office" />
Access Violation, General Protection Fault or Invalid Page Fault, the name changes, but the nature of the error is always the same. Access Violation is a phrase that users of personal computers see when an application they are running tries to access storage that is not designated for their use - and crashes.
Access violation at address <HEX_value>
in module <Application.Exe>.
Read of address <HEX_value_2>
If Windows applications were able to write outside of its assigned storage area, it could overwrite other applications' or the operating system's instructions and data. If that should happen, the operating system would "crash" or close down in some way and you would have to reboot the operating system. For example, when a program error occurs in Windows NT/2000, Dr. Watson steps in and stops the program, taking some quick diagnostic stats, recording them in a text file.
Access Violations are some of the most frustrating errors encountered in Windows programming. The purpose of this article is to help you find the solution to your AVs with Delphi. To start with, access violations have nothing to do with Microsoft Access.
We can divide AVs encountered while developing with Delphi in two major types: runtime and design time.
Access Violations at Design-Time
Design time AVs are experienced when starting and closing the Delphi IDE or building a Delphi project.
AV messages that crop up while your computer is in operation can be generated by various different sources, including the system BIOS, the operating system or hardware driver routines. Some video, sound or network cards can actually cause AVs in Delphi. Why? Every card in your machine comes with device drivers. Depending on the manufacturer, the version of Windows, and the version of Delphi used you may experience problems. There are some steps that can be taken to help resolve these issues:
· Take the steps necessary to verify that there are no conflicts between your installed devices.
· Sometimes lowering the resolution will help stabilize a quirky video card driver.
· Insure that if you are using a dual processor motherboard that the step revision for each processor is the same.
· Always use the latest driver for all of the components in your system.
Although Windows is the most popular operating system for Intel machines, due to the extreme fragility and bugginess of Windows, misbehaving applications can readily crash the OS (and the OS sometimes crashes itself spontaneously). There are ways that you can help your chances of having a more stable programming environment, which in turn will help to prevent certain AVs.
· Although Windows 9X is quite popular, Windows NT/2000 has proven to be a much more stable environment for almost all Windows coding platforms.
· Ensure that you have installed the latest service packs for NT/2000. With each service pack released, you will find that your machine will become more stable.
· One excellent method of proactive error prevention is to always keep the current with all updates and patches for whatever edition and version of Delphi (BDE, ADO, ...) that you are using. Always have the latest patch for Delphi - the number of AVs, especially design time violations, will drastically decrease.
· If you are getting random access violations in the IDE, you have most likely installed a bad component or package or a wizard that was not written/compiled for your Delphi version. Try uninstalling custom components one by one (or package by package) until the problem goes away, then get in touch with the component vendor regarding this issue.
· Check to see whether if there is anything unusual installed on the machine with the program that crashes. Curious shareware utilities and beta products are AV favorites.
· An access violation can also occur because a system setting is wrong. If you repeatedly encounter the same error message, record the details and call the company that makes the software that seems to be causing the message.
如果Windows应用程序能够写以外的其分配的存储区域,它可以覆盖其他应用程序'或作业系统的指令和数据。如果要发生,作业系统会“撞车”或倒闭,在某种程度上,你将不得不重新启动作业系统。举例来说,当一个程序中出现错误的Windows NT/2000 , 按Dr.Watson的步骤,并停止该计划,采取一些快速诊断的统计资料,记录他们在一个文本文件中。
存取违规是在Windows编程中遇到的一些最令人沮丧的错误。本文的目的是为了帮助您找到解决Delphi中的AVs。首先,存取违规已完全与Microsoft Access没有关系。
当您的计算机运作时可以产生各种不同的来源时AV讯息出现了,包括系统BIOS ,操作系统或硬件驱动程序例程。某些视频,声音或网路卡,其实可以在Delphi中导致AVs。为什么?每卡在您的机器附带的设备驱动程序。根据对制造商,该版本的Windows ,以及版本的Delphi中使用您可能会遇到的问题。也有一些可以采取的步骤,以帮助解决这些问题:
在英特尔的机器中,虽然Windows是目前最流行的操作系统,由于极端的脆弱性和漏洞,动作失常的申请可随时使操作系统崩溃(OS的崩溃,有时本身自发) 。有方法可以帮助您有机会拥有一个更稳定的编程环境,这反过来将有助于防止某些AVs。
虽然Windows 9x中颇为流行, Windows NT/2000已被证明是一个更为稳定的环境,几乎适用于所有的Windows平台的编码。
确保您已安装最新的Service Packnt/2000 。当每个Service Pack释放时,你会发现你的机器将变得更加稳定。
一个很好的方法,积极预防错误,是始终保持目前的所有更新和修补程序,无论您正在使用什么版本的Delphi BDE ADO的, … … )。永远拥有Delphi最新的修补程序, -AVs的数目,尤其是设计时间的行为,会大大减少。
Something about Delphi’s prominent information
Key features
- Support for three different personalities: Delphi for Win32, Delphi for .NET and C# all from within one development (and debugging) environment.
- Easy migration of Win32 applications to .NET within the same development environment.
- Support for the Delphi language with several enhancements like multi-unit namespaces, for ... in ... do loops, inline functions and other code optimisations.
- Support for WinForms, ASP.NET Web Forms as well as Borland´s own VCL framework on .NET, and VCL for Win32 with visual designers to build applications the RAD way.
- Support for heterogeneous database access (using any ADO.NET Data Adapter – not just BdpDataAdapter) as well as multi-tier database applications with new DataSync, DataHub, RemoteServer and RemoteConnection components.
- Support for refactoring to restructure your source code, increasing the maintainability and chances of successful reuse.
- Support for unit testing with DUnit and NUnit, using the extreme unit-test framework in Delphi for Win32, Delphi for .NET and C# projects to increase the quality of your code.
- Support for Enterprise Core Objects II - a UML compliant Object Model Framework and Object Persistence, with support for databases through the Borland Data Provider, and now also available for ASP.NET.
- Support for ASP.NET with DB Web controls to facilitate the design, implementation and deployment of powerful data-driven Web applications.
- Support for version and team development, with a special backup and history view of your project files, plus optional integration with StarTeam.
- Support for integration with J2EE Enterprise JavaBeans (EJB) or CORBA servers with the Janeva solution for Delphi for .NET and C# applications.
Project manager
The Delphi 2005 Project Manager now displays the directory structure of the entire project (and for ASP.NET projects even offers the ability to create and manage subdirectories in your project directory), which offers better insight into where files are placed and which files to deploy. Within a Project Group, we can add projects for different targets (and personalities), and switch from one project to another - and hence one personality to another, instantly.
The Project Manager and the Object Inspector now work together, as you can select a file in the Project Manager, which results in the Object Inspector showing information like the file name and full path, plus file specific properties like the culture, name and version number of assemblies, or the Copy Local option. Most of these properties will be read-only (displayed in grey font), while some can be used to actually change for example the filename or Copy Local status. The Project Manager is also StarTeam aware and offers context sensitive commands within the Project Manager for managing projects stored in StarTeam.
Backup and history
The Borland Delphi 2005 IDE transparently maintains multilevel backups and a history of your project source files in a hidden __history directory of your project directory. This replaces the old .~ files. The __history directory can contain multiple versions of your project (by default the latest 10 versions are maintained), and can be used as a local version control repository.
The History View is used to examine the current and backup versions of your project files, and even view at insightful (and intelligent) difference views between two different versions, showing exactly what you added, removed or modified in your source code. Apart from just looking at the differences, you can also revert changes, going back in time to backup versions of your files.
The History View also supports StarTeam for even more complete team view of your projects history (see ALM section).
-支持三种不同的个性:在同一开发(和调试)的环境中Delphi支持W in32.netC#。
-在同一开发环境中易于迁移的W in32应用程序与.net
-支持为Delphi语言与几个增强一样的多单元命名空间,for...in ...do loops,内置的功能和其他代码最佳化。
-支持Winforms asp.netWeb表格,以及Borland的自己的V CL框架在.NET内,为的Win32VCL与视觉设计师,以建立应用程序的RAD的方式。
-支持异构数据库Access(用任何ado.net数据适配器-不只是bd pdataadapter),以及多层数据库应用与新datasyncdatahubremoteserverre moteconnection组件。
-支持单元测试与DUnitNUnit,用精确的单元测试框架,在DelphiW in32 Delphi.NETC#项目,以增加您代码的质量。
-支持asp.netDB Web控件,以方便设计,执行和部署强大的数据驱动的Web应用程序。
-支持一体化与J2EEEnterprise JavaBeans技术( EJB技术)或CORBA的服务器与janeva的解决办法在Delphi.netC#的应用。
Borland公司的IDE Delphi保持透明,多层次的备份和历史,您的项目源文件在一个隐藏的目录_history您的项目目录。这将替换旧的.~ files。该_history目录可以包含多个版本的项目(默认情况下,最新的10个版本保持了),以及可被用来作为本地版本控制存放。历史上的看法是,用来检查当前和备份版本的项目文件,甚至在有见地的看法(智能)的不同意见之间的两个不同的版本,显示正是在您的源代码进行添加,去除或修改。除了刚才看到的分歧,您也可以回复的变化,回去的时间,以备份版本在您的档案。


验证码: 点击我更换图片
旺旺客服一客服 旺旺客服二客服