unit initform;

interface

uses
  Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs;

type
  TGlobalTestForm = class(TForm)
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  GlobalTestForm: TGlobalTestForm;

implementation

{$R *.DFM}
initialization begin
  MessageBox(0,'Luotu','1',0);
  GlobalTestForm := TGlobalTestForm.Create(Application);
end;

finalization begin
  MessageBox(0,'Tuhotaan','1',0);
  GlobalTestForm.Free;
  MessageBox(0,'Tuhotaan','2',0);
end;

end.
 