Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   Win32/Win64 API (native code) (https://www.delphipraxis.net/17-win32-win64-api-native-code/)
-   -   Delphi Icon einer EXE in eigenes PRog (https://www.delphipraxis.net/10487-icon-einer-exe-eigenes-prog.html)

Florian H 19. Okt 2003 18:10


Icon einer EXE in eigenes PRog
 
Hi,

wie kann ich das Icon einer beliebigen EXE-Datei zur Laufzeit in mein Programm integrieren, sodass ich es da als TBitmap beliebig weiterverarbeitenkann? gibt es da was?

grüße
florian

Alexander 19. Okt 2003 18:19

Re: Icon einer EXE in eigenes PRog
 
So müsste das gehen:
Delphi-Quellcode:
var
  FileInfo: SHFILEINFO;
begin
    SHGetFileInfo(PChar('Filename.exe'), 0, FileInfo, SizeOf(FileInfo), SHGFI_ICON);
    icon.Handle := FileInfo.hIcon;
end;

phlux 19. Okt 2003 18:19

Re: Icon einer EXE in eigenes PRog
 
Servus
vllt helfen die 2 links:
http://www.swissdelphicenter.ch/de/showcode.php?id=720
und
http://www.swissdelphicenter.ch/de/showcode.php?id=22

mfg phlux

Florian H 19. Okt 2003 19:04

Re: Icon einer EXE in eigenes PRog
 
ah super, danke euch beiden!!


Alle Zeitangaben in WEZ +1. Es ist jetzt 01:03 Uhr.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz