下面的方法就没问题,为什么呢?
var
handle_dll:Thandle;
cipher:procedure;
begin
......
try
handle_dll:=LoadLibrary('keyoper.dll');
if handle_dll<>null then
begin
@cipher:=GetProcAddress(handle_dll,
'putKeyToFile(Pchar(temp),Length(temp),i,Pchar(SaveDialog.FileName))');
if @cipher<>nil then cipher;
end
else
begin
showmessage('error dll');
end;
finally
FreeLibrary(handle_dll);
end;
......
end;
var
handle_dll:Thandle;
cipher:procedure;
begin
......
try
handle_dll:=LoadLibrary('keyoper.dll');
if handle_dll<>null then
begin
@cipher:=GetProcAddress(handle_dll,
'putKeyToFile(Pchar(temp),Length(temp),i,Pchar(SaveDialog.FileName))');
if @cipher<>nil then cipher;
end
else
begin
showmessage('error dll');
end;
finally
FreeLibrary(handle_dll);
end;
......
end;
对这些东西最不懂,还是来提前一下吧。 看看哪位高手能解决。