AGB  ·  Datenschutz  ·  Impressum  







Anmelden
Nützliche Links
Registrieren
Zurück Delphi-PRAXiS Programmierung allgemein Win32/Win64 API (native code) Delphi Herausfinden wie viele Icons in einer Datei integriert sind
Thema durchsuchen
Ansicht
Themen-Optionen

Herausfinden wie viele Icons in einer Datei integriert sind

Ein Thema von Zacherl · begonnen am 25. Jun 2005 · letzter Beitrag vom 25. Jun 2005
Antwort Antwort
Benutzerbild von Zacherl
Zacherl

Registriert seit: 3. Sep 2004
4.629 Beiträge
 
Delphi 10.2 Tokyo Starter
 
#1

Herausfinden wie viele Icons in einer Datei integriert sind

  Alt 25. Jun 2005, 15:44
Hallo,
wie kann mit Delphi die Anzahl von Icons, die in einer Datei sind ermitteln?
In z.B. Shell32.dll sind viele Icons als Ressource eingebunden...Die Funktion soll die genaue Zahl ermitteln.

Florian
Projekte:
- GitHub (Profil, zyantific)
- zYan Disassembler Engine ( Zydis Online, Zydis GitHub)
  Mit Zitat antworten Zitat
Benutzerbild von Kroko1999
Kroko1999

Registriert seit: 21. Apr 2005
Ort: Spremberg
455 Beiträge
 
Turbo Delphi für Win32
 
#2

Re: Herausfinden wie viele Icons in einer Datei integriert s

  Alt 25. Jun 2005, 15:49
Zitat:
The ExtractIcon function retrieves the handle of an icon from the specified executable file, dynamic-link library (DLL), or icon file.

HICON ExtractIcon(

HINSTANCE hInst, // instance handle
LPCTSTR lpszExeFileName, // filename of file with icon
UINT nIconIndex // index of icon to extract
);


Parameters

hInst

Identifies the instance of the application calling the function.

lpszExeFileName

Points to a null-terminated string specifying the name of an executable file, DLL, or icon file.

nIconIndex

Specifies the index of the icon to retrieve. If this value is 0, the function returns the handle of the first icon in the specified file. If this value is -1, the function returns the total number of icons in the specified file.



Return Values

If the function succeeds, the return value is the handle to an icon. If the file specified was not an executable file, DLL, or icon file, the return is 1. If no icons were found in the file, the return value is NULL.
Da sprach der Stumme zum Blinden: "Du wirst sehen ..."
oder
Wer lesen kann, ist klar im Vorteil!
  Mit Zitat antworten Zitat
Benutzerbild von Zacherl
Zacherl

Registriert seit: 3. Sep 2004
4.629 Beiträge
 
Delphi 10.2 Tokyo Starter
 
#3

Re: Herausfinden wie viele Icons in einer Datei integriert s

  Alt 25. Jun 2005, 15:53
Danke,
dann muss ich wohl die Funktion benutzen. Habs vorher mit ExtractAssociatedIcon aus der ShellAPI gemacht.

Florian
Projekte:
- GitHub (Profil, zyantific)
- zYan Disassembler Engine ( Zydis Online, Zydis GitHub)
  Mit Zitat antworten Zitat
scp

Registriert seit: 31. Okt 2003
1.120 Beiträge
 
Delphi 7 Personal
 
#4

Re: Herausfinden wie viele Icons in einer Datei integriert s

  Alt 25. Jun 2005, 15:57
Ich dachte du wolltest die Anzahl usw. wissen?

In Delphi 7 (und bei älteren) gibt es eine Demo, mit der man gut sehen kann, wie die Header und Sections einer EXE ausgewertet werden können. Schau mal unter Delphi7\Demos\ResXplor.

EDIT: Kommentar in der Beschreibung übersehen.
  Mit Zitat antworten Zitat
Antwort Antwort


Forumregeln

Es ist dir nicht erlaubt, neue Themen zu verfassen.
Es ist dir nicht erlaubt, auf Beiträge zu antworten.
Es ist dir nicht erlaubt, Anhänge hochzuladen.
Es ist dir nicht erlaubt, deine Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Trackbacks are an
Pingbacks are an
Refbacks are aus

Gehe zu:

Impressum · AGB · Datenschutz · Nach oben
Alle Zeitangaben in WEZ +1. Es ist jetzt 16:08 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