Gets executable file's icon.
Unit
Syntax
ParametersADPI [in, optional] DPI settings (96, 120, etc.). Pass 0 to use defaults.
AFileName [in] Full executable file name (.exe, .dll, .bpl).
ALarge [in] True - extract large icon, False - extract small icon.
Icon sizes are determinated from system settings and DPI. Usually it's values like 40x40 or 32x32 for large size and 20x20 or 16x16 for small size.
ASz [out, optional] Actual icon size in pixels. Caller may use this value for rendering resulting icon.
This value is undefined if function fails.
Return valueIf the function succeeds, the return value is default icon's handle of the specified file.
If the function fails, the return value is zero. To get extended error information, call GetLastError.
RemarksCreates handle to large or small icon extracted from the specified executable file, DLL, or package.
You must destroy all icons extracted by GetFileIcon by calling the DestroyIcon function.
|