From RAD Studio API Documentation
Jump to: navigation, search


property ParentWindow: HWND read FParentWindow write SetParentWindow;


__property HWND ParentWindow = {read=FParentWindow, write=SetParentWindow, nodefault};


Type Visibility Source Unit Parent
property public
Vcl.Controls TWinControl


Reference to parent's underlying control.

ParentWindow refers to the window handle that underlies the parent control. To designate a non-VCL control as a parent, assign that control's handle to ParentWindow. This assignment causes the control to be moved into the parent's screen area. Setting ParentWindow has no effect if Parent is not nil (Delphi) or NULL (C++).

TActiveXControl objects use ParentWindow to insert a control in an ActiveX container window. ParentWindow is set automatically when a control is constructed with a call to CreateParented (Delphi) or the appropriate overloaded constructor (C++).

Use ParentWindow with windowed controls that are packaged in a DLL. This allows references to the control by applications based on other applications.

See Also