L
littlexb
Unregistered / Unconfirmed
GUEST, unregistred user!
我的dll中是这样写的:
procedure cls(obj:Tmemo);stdcall;
begin
if obj<>nil then obj.clear
//运行到这里出错
end;
exports
cls;
我的主程序是这样写的:
Tmyproc = procedure (obj:Tmemo);stdcall;
var myproc1:Tmyproc
prochandle:=loadlibrary(pchar('project1.dll'));
if prochandle<>0 then
begin
@myproc1:=getprocaddress(prochandle,pchar('cls'));
if @prochandle<>nil then myproc1(memo1);
end;
freelibrary(prochandle);
procedure cls(obj:Tmemo);stdcall;
begin
if obj<>nil then obj.clear
//运行到这里出错
end;
exports
cls;
我的主程序是这样写的:
Tmyproc = procedure (obj:Tmemo);stdcall;
var myproc1:Tmyproc
prochandle:=loadlibrary(pchar('project1.dll'));
if prochandle<>0 then
begin
@myproc1:=getprocaddress(prochandle,pchar('cls'));
if @prochandle<>nil then myproc1(memo1);
end;
freelibrary(prochandle);