好象不对,应该是: type TPEImports = record string1: string; end; TPEImportsArray = array of TPEImports; // 需要定义这两个类型 PTPEImportsArray = ^TPEImportsArray;procedure foo( p: PTPEImportsArray ); begin ShowMessage( p^[1].string1 ); end;
var Imports: array of TPEImports; a: array of TPEImports; begin pefile1:=tpefile.Create('c:\a.exe'); a:[email protected]; showmessage(a[0].dllname);//这句老是打出来乱码 end;
type
TPEImports = record
string1: string;
end; TPEImportsArray = array of TPEImports; // 需要定义这两个类型
PTPEImportsArray = ^TPEImportsArray;procedure foo( p: PTPEImportsArray );
begin
ShowMessage( p^[1].string1 );
end;
Imports: array of TPEImports;
a: array of TPEImports;
begin
pefile1:=tpefile.Create('c:\a.exe');
a:[email protected];
showmessage(a[0].dllname);//这句老是打出来乱码
end;