[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] | Reference for unit 'Graphics' (#lcl)

# TIcon.ReleaseHandle

Frees the Handle used for the shared image in the Icon.

## Declaration

Source position: graphics.pp line 1690

`public function TIcon.ReleaseHandle: HICON;`

## Function result

HICON value removed from the handle in the class instance.

## Description

Calls HandleNeeded to ensure that a handle is assigned if it does not already exist. Calls the ReleaseHandle method in the shared raster image used for the icon. The return value is the handle for the shared raster image before it is set to the unassigned value (0).