Struktur Program Delphi

  • Program console (Dos)

Program Project1;

{$AppType CONSOLE}

uses
  SysUtils;

var
  name : string;

begin
  WriteLn('Please enter your name');
  ReadLn(name);
  WriteLn('Your name is '+name);
  WriteLn('');
  WriteLn('Press enter to exit');
  ReadLn(name);
end.


  • Program Windows
Program Project1;

uses
  Forms,
  Unit1 in 'Unit1.pas' {Form1};

{$R *.res}

begin
  Application.Initialize;
  Application.CreateForm(TForm1, Form1);
  Application.Run;
end.

0 komentar:

Posting Komentar