Vcl.ImgList.TCustomImageList.GetResource

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

function GetResource(ResType: TResType; const Name: string;  Width: Integer; LoadFlags: TLoadResources; MaskColor: TColor): Boolean;

C++

bool __fastcall GetResource(TResType ResType, const System::UnicodeString Name, int Width, TLoadResources LoadFlags, System::Uitypes::TColor MaskColor);

Properties

Type Visibility Source Unit Parent
function public
Vcl.ImgList.pas
Vcl.ImgList.hpp
Vcl.ImgList TCustomImageList

Description

Loads the specified bitmap, cursor, or icon resource into the image list.

Use the GetResource method to load bitmap, cursor, or icon resource into an image list.

Note: Within a package, GetResource returns an error. GetInstRes must be used to load a resource from within a package.

ResType specifies the type of graphical resource that is to be loaded into the image list and can be rtBitmap, rtCursor or rtIcon.

Name identifies the resource by name.

Width specifies the width, in pixels, of the image.

LoadFlags specifies how to load the image.

MaskColor sets the transparent color for the images in the file.

See Also