All the modal forms are displayed at Left Top of the screen while the setting are as Follows
BorderIcons = [biSystemMenu]
BorderStyle = bsSingle
Position = poOwnerFormCenter
Earlier it used to be display as per setting but recently i made some changes which causes the problem
Let me explain further so you can suggest appropriate solution.
My application has almost more than 50 forms and i open them as CustomerForm.Show/ShowModal. All forms are inherited from one root form which has following code to display icon on task bar
procedure TBaseForm.CreateParams(var Params: TCreateParams);
begin
inherited CreateParams(Params);
Params.ExStyle := Params.ExStyle or WS_Ex_AppWindow;
Params.WndParent := GetDesktopwindow;
end;
There was one problem that whenever a file open or file save dialog was opened from any form(whether it is modal form or not) , Main form was coming at Top, to fix this i made a Dummy Main Form and
put Application.ShowMainForm := false;
in project file and this worked fine but this started all modal form appearing at Left Top Corner of the screen.
Can you please suggests on this?
Params.WndParent := GetDesktopwindow
looks wrong to me. – David Heffernan