Точнее не читается имя ресурса в файле "calc.exe"... Ресурс типа Icon Group... Называется "SC"... В то время как другие файлы читаются без проблем!!! Читаю таким кодом:
Код:
function StockResourceType(ResType: PChar): string;
begin
if ResType = PChar(14) then
Result:='RT_GROUP_ICON';
end;
function EnumResNamesProc(Module: HMODULE; ResType, ResName: PChar; Ts: TStrings): Integer; stdcall;
begin
if (StockResourcetype(ResType) = 'RT_GROUP_ICON') then
begin
if HiWord(Cardinal(ResName)) = 0 then
Ts.Add(Format('%d', [loword(Cardinal(resname))]));
end;
Result:=1;
end;
function EnumResTypesProc(Module: HMODULE; ResType: PChar; Ts: TStrings): Integer; stdcall;
begin
if (StockResourcetype(restype) = 'RT_GROUP_ICON') then
begin
EnumResourceNames(Module, ResType, @EnumResNamesProc, Integer(Ts));
end;
Result:=1;
end;
...
var
LoadLib: THandle;
Sl: TStringList;
begin
LoadLib:=LoadLibrary(PChar('c:\calc.exe'));
Sl:=TStringList.Create;
EnumResourceTypes(LoadLib, @EnumResTypesProc, Integer(Sl));
ShowMessage(Sl.Strings[0]);
....
end;
Мне конечно не принципиально... Но все же интерестно что это может быть... Заранее благодарен...