Icons.FromFile Method (String, SystemIconSize)

KGy SOFT Drawing Libraries

IconsFromFile Method (String, SystemIconSize) KGy SOFT Drawing Libraries Help
Extracts icons of the specified size from a file and returns them as separated Icon instances.

Namespace: KGySoft.Drawing
Assembly: KGySoft.Drawing (in KGySoft.Drawing.dll) Version: 4.6.0
Syntax

public static Icon[] FromFile(
	string fileName,
	SystemIconSize size
)
Public Shared Function FromFile ( 
	fileName As String,
	size As SystemIconSize
) As Icon()
public:
static array<Icon^>^ FromFile(
	String^ fileName, 
	SystemIconSize size
)
static member FromFile : 
        fileName : string * 
        size : SystemIconSize -> Icon[] 

Parameters

fileName
Type: SystemString
The name of the file. Can be an executable file, a .dll or icon file.
size
Type: KGySoft.DrawingSystemIconSize
The size of the icons to be extracted.

Return Value

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

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.

See Also

Reference