home *** CD-ROM | disk | FTP | other *** search
- unit Main;
-
- interface
-
- uses
- Windows, Classes, Controls, Forms, StdCtrls, Buttons, ExtCtrls,
- FormMagnet;
-
-
- type
- TForm1 = class(TForm)
- Panel1: TPanel;
- BitBtn1: TBitBtn;
- BitBtn2: TBitBtn;
- ScrollBox: TScrollBox;
- Label1: TLabel;
- Label2: TLabel;
- FormMagnet1: TFormMagnet;
- procedure BitBtn1Click(Sender: TObject);
- procedure BitBtn2Click(Sender: TObject);
- private
- { Private declarations }
- public
- { Public declarations }
- end;
-
- var
- Form1: TForm1;
-
- implementation
-
- {$R *.DFM}
-
- uses Unit2, Unit3;
-
- procedure TForm1.BitBtn1Click(Sender: TObject);
- var
- TempForm: TWindow;
- begin
- Application.CreateForm(TWindow, TempForm);
- TempForm.Visible := True;
- end;
-
- procedure TForm1.BitBtn2Click(Sender: TObject);
- var
- TempForm: TSubWindow;
- begin
- Application.CreateForm(TSubWindow, TempForm);
- TempForm.Left := 0;
- TempForm.Top := Panel1.Height + 2;
- TempForm.Parent := ScrollBox;
- end;
-
- end.
-