(Gast)
n/a Beiträge
|
Re: Icon aus fremder EXE laden
1. Aug 2007, 22:01
Hallo,
probier es mal hiermit:
Delphi-Quellcode:
//Icon einer Datei auslesen
procedure TfrmMain.GetIconFromFileB(const FileName: String; Icon: TIcon; SmallIcon: Boolean);
var
sfi: TShFileInfo;
const
uFlags : array[Boolean] of DWord = (SHGFI_LARGEICON, SHGFI_SMALLICON);
begin
if SHGetFileInfo(PChar(FileName), 0, sfi, SizeOf(sfi), SHGFI_ICON or uFlags[SmallIcon]) <> 0 then
begin
Icon.Handle := sfi.hIcon;
end;
end;
|
|
Zitat
|