{PROJECT1.DPR}
program Project1;
uses
Forms,SysUtils,
Unit1 in ′Unit1.pas′ {Form1},
Splash in ′..\..\Demos\DB\MASTAPP\Splash.pas′ {SplashForm};
{R *.RES}
var time1:TDateTime;
begin
SplashForm:=TSplashForm.Create(Application);
SplashForm.Show;
SplashForm.Refresh;
time1:=now;
repeat
until time1+StrtoTime(′00:00:5′)<=now;
Application.Initialize;
Application.CreateForm(TForm1, Form1);
Application.Run;
end.
{UNIT1.PAS 主窗体}
unit Unit1;
interface
uses
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms,
Dialogs,splash;
type
TForm1 = class(TForm)
procedure FormShow(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
implementation
{R *.DFM}
procedure TForm1.FormShow(Sender: TObject);
begin
SplashForm.Free;
end;
end.
{SPLASH.PAS Splash窗体}
unit Splash;
interface
uses
SysUtils, Windows, Messages, Classes, Graphics, Controls,
Forms, Dialogs, StdCtrls, ExtCtrls;
type
TSplashForm = class(TForm)
Panel1: TPanel;
Label3: TLabel;
Bevel1: TBevel;
Label1: TLabel;
Image1: TImage;
end;
var
SplashForm: TSplashForm;
implementation
{R *.DFM}
end.
|