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

# TApplication.HandleMessage

Handles pending messages, and enters the Idle state.

## Declaration

Source position: forms.pp line 1614

`public procedure TApplication.HandleMessage;`

## Description

HandleMessage is a method used to process pending window or control messages in the application. It calls the AppProcessMessages method in the widgetset class to handle pending messages. It calls the Idle method to enter the idle state where queued asynchronous callbacks can be handled and idle handlers can be signalled.

It is very similar to the ProcessMessages method, which does not signal idle handlers for the application or wait for a new message before exit.

HandleMessage is called from the private RunLoop method in TApplication.