{ from http://ccrun.com/article/go.asp?i=653&d=b2m5o1 }
uses ImageHlp;
function GetDLLFileExports( szFileName: PChar; mStrings: TStrings ): Boolean; var hFile: THANDLE; hFileMapping: THANDLE; lpFileBase: Pointer; pImg_DOS_Header: PImageDosHeader; pImg_NT_Header: PImageNtHeaders; pImg_Export_Dir: PImageExportDirectory; ppdwNames: ^PDWORD; szFunc: PChar; i: Integer; begin Result := False; if not Assigned(mStrings) then Exit; hFile := CreateFile(szFileName, GENERIC_READ, FILE_SHARE_READ, nil, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, 0); if(hFile = INVALID_HANDLE_VALUE) then Exit; hFileMapping := CreateFileMapping(hFile, nil, PAGE_READONLY, 0, 0, nil); if hFileM[1] [2] [3] [4] 下一页
|
|