我的DLL上放了一个Form,上面放一个query,datasource,dbgrid,一个Button
Button的click事件:Query1.open;我在DLL里运行的时候,一切正常,按下button出现数据,然后关掉dll中的form,再关掉主调用程序的form时,就先出现如下错误信息:
Project D:\CallDll\Project1.exe faulted with message:'access violation at
0x4be43541:read of address 0xfff82798'.Process stopped.Use Step or Run to continue.然后就出现那个CPU汇编调试对话框,请问是怎么回事啊???
Button的click事件:Query1.open;我在DLL里运行的时候,一切正常,按下button出现数据,然后关掉dll中的form,再关掉主调用程序的form时,就先出现如下错误信息:
Project D:\CallDll\Project1.exe faulted with message:'access violation at
0x4be43541:read of address 0xfff82798'.Process stopped.Use Step or Run to continue.然后就出现那个CPU汇编调试对话框,请问是怎么回事啊???
解决方案 »
- 请问各位高手,Delphi怎么在指定的地方嵌入(链接)别的窗体呢?
- delphi如何实现只运行一个实例,且激活第一个实例中的某个窗体?
- delphi2005--indy10中邮件加载附件与以前不同了!求助!!!
- delphi数据库操作时,如何直接捕获到SQL Server错误消息代码
- 邻居得了奥运金牌,替他高兴,散分~~
- 上面下死任務﹕讓我對一個已做好的程序做最后的打包﹐望高手指點﹐分不夠可以再加﹗
- 请问如何连续添加6条空记录?
- 这条sql语句哪里出错了
- ConnectionString的provider问题(在线等待,马上给分)
- 如何开发能在NT中执行的服务程序
- 怎样发送Raw IP数据包
- 顺便问个今天遇到的问题:
把你button click事件写出来看看
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, DB, ADODB, StdCtrls,QuickRpt, ExtCtrls, RpDefine, RpRave,
DBTables, RpCon, RpConDS, Grids, DBGrids;type
TfrmuMain = class(TForm)
ADOConnection1: TADOConnection;
Button1: TButton;
Query1: TQuery;
Button2: TButton;
DataSource1: TDataSource;
DBGrid1: TDBGrid;
Edit1: TEdit;
procedure Button1Click(Sender: TObject);
procedure Button2Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;procedure ReportForms(H: THandle; AConn: TADOConnection); cdecl;var
frmuMain: TfrmuMain;implementation{$R *.dfm}procedure ReportForms(H: THandle; AConn: TADOConnection);
begin
Application.Handle := H;
with TfrmuMain.Create(Application) do
try
ADOConnection1 := AConn; { 获得数据库连接的实例 }
ShowModal;
finally
Free;
end;
end;procedure TfrmuMain.Button1Click(Sender: TObject);
begin
query1.Open ;
end;procedure TfrmuMain.Button2Click(Sender: TObject);
begin
// RvProject1.Execute ;
query1.Close ;
end;end.
*********************************************
我用的是BDE连接的数据库,是不是这个方面的问题???