Einzelnen Beitrag anzeigen

Benutzerbild von negaH
negaH

Registriert seit: 25. Jun 2003
Ort: Thüringen
2.950 Beiträge
 
#3

Re: Icons aus Systembibliothek (*.icl) extrahieren?

  Alt 16. Sep 2003, 10:41
ICL's sind normale DLL's.

Delphi-Quellcode:
procedure ExtractICLIcon(Icon: TIcon; const FileName: String; IconIndex: Integer);
var
  Lib: THandle;
begin
  Lib := LoadLibraryEx(PCHar(FileName), 0, LOAD_LIBARARY_AS_DATAFILE);
  if Lib <> 0 then
  try
    Icon.Handle := ExtractIcon(Lib, IconIndex);
  finally
    FreeLibrary(Lib);
  end;
end;
Gruß Hagen
  Mit Zitat antworten Zitat