dll窗口输出函数:
function ShowDll_FYCFCX(A: TApplication): Bool;
var
Form1: TfrmFYCFCX;
begin
Application.Handle := A.Handle;
Form1 := TfrmFYCFCX.Create(A);
try
Result := (Form1.ShowModal = mrOK);
finally
Form1.Free;
end;
end;
菜单加载dll的代码:
procedure Tfrm_Main.N27Click(Sender: TObject);
var
LibHandle: THandle;
ShowForm: TShowForm;
begin
LibHandle := LoadLibrary('Fxcfcx_dll.dll');
try
if LibHandle = HINSTANCE_ERROR then
raise EDLLLoadError.Create('Unable to Load DLL');
@ShowForm := GetProcAddress(LibHandle, 'ShowDll_FYCFCX');
if not (@ShowForm = nil) then
ShowForm(Application);
finally
FreeLibrary(LibHandle);
end;
end;问题在哪呢?
function ShowDll_FYCFCX(A: TApplication): Bool;
var
Form1: TfrmFYCFCX;
begin
Application.Handle := A.Handle;
Form1 := TfrmFYCFCX.Create(A);
try
Result := (Form1.ShowModal = mrOK);
finally
Form1.Free;
end;
end;
菜单加载dll的代码:
procedure Tfrm_Main.N27Click(Sender: TObject);
var
LibHandle: THandle;
ShowForm: TShowForm;
begin
LibHandle := LoadLibrary('Fxcfcx_dll.dll');
try
if LibHandle = HINSTANCE_ERROR then
raise EDLLLoadError.Create('Unable to Load DLL');
@ShowForm := GetProcAddress(LibHandle, 'ShowDll_FYCFCX');
if not (@ShowForm = nil) then
ShowForm(Application);
finally
FreeLibrary(LibHandle);
end;
end;问题在哪呢?
解决方案 »
- fastreport 数值比较的问题
- 如何加序号列?
- access 库 保from错,哪位高手能解决一下,谢谢了!
- 请解释解释这个语法的意思????????
- fffff
- 关于动态创建窗体时窗体间的数据传递!谢谢!急用!
- 在Delphi中如何显示“水晶报表”的“子报表”
- 一首老歌
- 我的delphi2007为什么在状态栏显示两个图标?
- 关闭应用程序总是提示“access violation at address XXXXXX in module *.ocx read of address FFFFFFF” 是怎么回事?各位大虾帮帮小弟。^-^
- 无法用ADO连接Access数据库.
- 怎样把 select 检索到的值传到edit.text中
我的窗体不是最小化,而是在DLL中的调用了APPLICATION的方法后主窗体最小化,当关闭DLL窗体
后主窗体又恢复了
不知该如何解决