将formstyle设为fsmidform.子设成fsmidchild.

解决方案 »

  1.   

    API:
    The SetParent function changes the parent window of the specified child window. HWND SetParent(
      HWND hWndChild,      // handle to window whose parent is changing
      HWND hWndNewParent   // handle to new parent window
    );
     
    VCL:
    Sets the parent of the control.procedure SetParent(AParent: TWinControl); virtual;
    DescriptionSetParent is the protected implementation of the Parent property. Override SetParent to execute additional code when the value of the Parent property changes.The AParent parameter specifies the new parent of the control.If the control already has a parent, SetParent removes the control from that parent's list of controls by calling the parent's RemoveControl method. If AParent is not nil, SetParent calls its InsertControl method to add the control to its list of controls.The TControl destructor calls SetParent(nil)to remove the control from its parent's control list before destroying the component.
      

  2.   


    self.Parent:=XXX;
    Parent: IComponent
      

  3.   

    同意eulb(执子之手,与子偕老) , 用法如下:SetParent(aForm.Handle, aParentForm.Handle);其中,aForm是你要改的窗体, aParentForm是改动后的父窗体
      

  4.   

    delphi开发人员指南上有例程,你看一下就可以了