RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
Forms.AllocateHWnd Function

Creates a window that implements a specified window procedure.

Pascal
function AllocateHWnd(Method: TWndMethod): HWND; deprecated;
C++
HWND AllocateHWnd(TWndMethod Method);

Forms

Call AllocateHWnd to create a window that is not associated with a windowed control. Typically, this method is used to create non-visual windows that respond to messages but that do not appear in the user interface. For example, the TTimer component uses this method to create a window that responds to timer messages from Windows.  

The Method parameter specifies the window procedure that the generated window uses to respond to messages.  

AllocateHWnd returns the handle of the newly created window.

Note: Use the DeallocateHWnd procedure to free windows that are created using AllocateHWnd.
 

 

DeallocateHWnd 

TTimer

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!