E
eire
Unregistered / Unconfirmed
GUEST, unregistred user!
DLL:
function _Connection(Params:variant;rRecords:TStrings):Boolean;stdcall;
调用:
function connect(Params:variant;ST:TSTRINGS):BOOLEAN;Stdcall;external 'TEST.dll' name
'_Connection';
VAR
SSS:TSTRINGLIST;
Begin
if not init(self.Handle) then
exit;
A := VarArrayCreate([0, 6], varVariant);
A[0] := 'XXXXXXXXXXXXX';
A[1] := 'XXX';
SSS:=tstringlist.Create;
// SSS.free;//如果在这儿FREE的话没有问题.
try
connect(a,sss)
Memo1.lines.assign(sss);
finally
freeandnil(sss);
///出错:Invalid pointer operation.
end;
end;
function _Connection(Params:variant;rRecords:TStrings):Boolean;stdcall;
调用:
function connect(Params:variant;ST:TSTRINGS):BOOLEAN;Stdcall;external 'TEST.dll' name
'_Connection';
VAR
SSS:TSTRINGLIST;
Begin
if not init(self.Handle) then
exit;
A := VarArrayCreate([0, 6], varVariant);
A[0] := 'XXXXXXXXXXXXX';
A[1] := 'XXX';
SSS:=tstringlist.Create;
// SSS.free;//如果在这儿FREE的话没有问题.
try
connect(a,sss)
Memo1.lines.assign(sss);
finally
freeandnil(sss);
///出错:Invalid pointer operation.
end;
end;