> Try Screen.ActiveForm.

Bingo. Thanks.

>
> I put the following code into a form that can be created from many
different
> forms so that it shows up centered inside the
> form from which the create originated.
>
> procedure TfrmNotes.FormShow(Sender: TObject);
> var
>     T,L,H,W : integer;
> begin
>   with ???????? do begin
>        T := Top;
>        L := Left;
>        H := Height;
>        W := Width;
>   end;
>   Top := T + (H div 2) - Height div 2;
>   Left := L + (W Div 2) - Width div 2;
> end;
>
> Is there a generic entry I can replace the ?????????? with that identifies
> the form from which the create originated?
>


---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED] 
with body of "unsubscribe delphi"

Reply via email to