IconsFromFile(String) Method

Extracts dual-resolution icons from a file and returns them as separated Icon instances.


Namespace: KGySoft.Drawing
Assembly: KGySoft.Drawing (in KGySoft.Drawing.dll) Version: 8.1.0
public static Icon[] FromFile(
	string fileName


fileName  String
The name of the file. Can be an executable file, a .dll or icon file.

Return Value

The icons of the specified file, or an empty array if the file does not exist or does not contain any icons.


If fileName refers to an icon file use the Icon(String) constructor instead.

The images of an Icon can be extracted by the IconExtensions.ExtractBitmaps methods.


On non-Windows platforms this method always returns an empty array.

See Also