Vcl.Forms.TApplication.ProcessMessages

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

procedure ProcessMessages;

C++

void __fastcall ProcessMessages();

Properties

Type Visibility Source Unit Parent
procedure
function
public
Vcl.Forms.pas
Vcl.Forms.hpp
Vcl.Forms TApplication

Description

Interrupts the execution of an application so that it can process the message queue.

Call ProcessMessages to permit the application to process messages that are currently in the message queue. ProcessMessages cycles the Windows message loop until it is empty, and then returns control to the application.

Note: Neglecting message processing affects only the application calling ProcessMessages, not other applications. In lengthy operations, calling ProcessMessages periodically allows the application to respond to paint and other messages.

Note: ProcessMessages does not allow the application to go idle, whereas HandleMessage does.

See Also

Code Examples