Setting Application.Handle as a top-level window' owner
- by Serg
I want the main form to appear above some other application forms (in z-order), so I override CreateParams method for these forms as follows:
procedure TForm3.CreateParams(var Params: TCreateParams);
begin
inherited;
Params.WndParent:= Application.Handle;
end;
I know the Application.Handle was the top-level windows' owner before Vista (and Delphi 2007). What is wrong with it in Vista (and Windows 7)? What potential problems may arise if I set Application.Handle as a top-level window owner?