Since Delphi 2007/2009, VCL has changed its behavior regarding the parent of the form. In Delphi 1-2006, the parent of the form was a hidden application window (Application.Handle). In Delphi 2007/2009, the parent of the form is the main form, and the main parent of the form is the desktop.
, *.dpr Application.MainFormOnTaskbar False, , Vista Windows 7. CreateParams Params.WndParent (HWND_DESKTOP) Application.Handle.
type
TMyChildForm = class(TForm)
protected
procedure CreateParams(var Params: TCreateParams); override;
end;
procedure TForm1.CreateParams(var Params: TCreateParams);
begin
inherited CreateParams(Params);
Params.WndParent := Application.Handle;
end;