TCustomIcon.LoadFromResourceID procedure
Load icon data from a resource with the specified integer resource identifier.
Declaration
procedure LoadFromResourceID(Instance: TLCLHandle; ResID: PtrInt)
; overrideDescription
LoadFromResourceID is an overridden procedure used to load a
resource with the specified Resource ID into the class instance.
LoadFromResourceID re-implements the method defined in the ancestor class,
and does not call the inherited method.
Instance contains the handle used to read the resource.
ResID contains an Integer pointer to the resource identifier
loaded in the method.
LoadFromResourceID calls GetResourceType to get the
Integer resource type used in the class instance. No actions are
performed in the method when the TResourceType value is unassigned
(contains Nil).
LoadFromResourceName calls FindResource to get the resource handle
needed in the method. An EResNotFound exception is raised if a
resource with the specified ID and type is not found in FindResource.
LoadFromResourceName calls LoadFromResourceHandle to load the icon
using the Instance and resource handle values.
Use LoadFromResourceName to load a resource with a given resource
name.
Use LoadFromLazarusResource to load a Lazarus resource from a
.lrs file with a give name.
Errors
Raises an EResNotFound exception if the resource handle for the specified ID and type is not valid.
See also
An experiment, built from Lazarus main 2dfa93c66e of 10-22-2026. Not the official Lazarus documentation.
