Anda di halaman 1dari 43

Kata Pengantar

Puji syukur saya panjatkan ke hadirat Tuhan Yang Maha Esa, karena dengan pertolonganNya
saya dapat menyelesaiakan UAS Delpi. Meskipun banyak rintangan dan hambatan yang saya
alami dalam proses pengerjaannya, tapi saya berhasil menyelesaikannya dengan baik.
Tak lupa saya mengucapkan terimakasih kepada teman-teman mahasiswa yang telah membantu
saya dalam mengerjakan UAS ini.
Tentunya ada hal-hal yang ingin saya berikan kepada masyarakat dari hasil karya ilmiah ini.
Karena itu saya berharap semoga karya ilmiah ini dapat menjadi sesuatu yang berguna bagi kita
bersama.
Pada bagian akhir, saya akan mengulas tentang berbagai masukan dan pendapat dari orang-orang
yang ahli di bidangnya, karena itu saya harapkan hal ini juga dapat berguna bagi kita bersama.
Semoga UAS yang saya buat ini dapat membuat kita mencapai kehidupan yang lebih baik lagi.

Penyusun

Tugas 1.
Tampilan desain form

Pesan 1 akan menampilkan gambar di bawah ini

Pesan 2 akan menampilkan gambar di bawah ini

Pesan 3 akan menampilkan gambar di bawah ini

Tombol tutup lihat gambar di bawah ini

Source code
unit ULat1;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ExtCtrls, jpeg;
type
TForm2 = class(TForm)
Button1: TButton;
Button2: TButton;
Button3: TButton;
Button4: TButton;
Shape1: TShape;
Label1: TLabel;
Label2: TLabel;
Image1: TImage;
procedure Button1Click(Sender: TObject);
procedure Button2Click(Sender: TObject);
procedure Button3Click(Sender: TObject);
procedure Button4Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;

var
Form2: TForm2;
implementation
uses UMenuUtama, ULat2, ULat3, ULat4, ULat5, ULat6;
{$R *.dfm}
procedure TForm2.Button1Click(Sender: TObject);
begin
ShowMessage('pesan 1 ini menggunakan show message');
ShowMessage('pesan 2 ini menggunakan show message');
end;
procedure TForm2.Button2Click(Sender: TObject);
begin
MessageDlg('pesan 1 ini menggunakan messageDlg',mtWarning,mbOKCancel,0);
MessageDlg('pesan 2 ini menggunakan messageDlg',mtInformation,mbYesNoCancel,0);
end;
procedure TForm2.Button3Click(Sender: TObject);
begin
Application.MessageBox('pesan 1 menggunakan
application.MessageBox','delphi',MB_OK+MB_ICONASTERISK);
Application.MessageBox('pesan 2 menggunakan
application.MessageBox','budiman',MB_YESNO+MB_ICONQUESTION);
end;
procedure TForm2.Button4Click(Sender: TObject);
begin
Close;
end;
end.

tugas 2.
Tampilan form

Pengisian DATA SUMBER

Penginputan SIMPAN DATA SUMBER

Penginputan COBA LAGI

Penginputan tombol TUTUP

Source code
unit ULat2;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ExtCtrls, jpeg;
type
TForm3 = class(TForm)
Shape1: TShape;
Label1: TLabel;
GroupBox1: TGroupBox;
Label2: TLabel;
Label3: TLabel;
Label4: TLabel;
Label5: TLabel;
Edit1: TEdit;
Edit2: TEdit;
Edit3: TEdit;
Edit4: TEdit;
GroupBox2: TGroupBox;
Label6: TLabel;
Label7: TLabel;
Label8: TLabel;
Label9: TLabel;
Edit5: TEdit;
Edit6: TEdit;
Edit7: TEdit;
Edit8: TEdit;
Button1: TButton;

Button2: TButton;
Button3: TButton;
Label10: TLabel;
Image1: TImage;
procedure FormShow(Sender: TObject);
procedure Button1Click(Sender: TObject);
procedure Button2Click(Sender: TObject);
procedure Button3Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
procedure bersihkan;
end;
var
Form3: TForm3;
implementation
uses ULat1, UMenuUtama, ULat3, ULat4, ULat5, ULat6;
{$R *.dfm}
procedure TForm3.Bersihkan;
begin
edit1.Clear;
edit2.Clear;
edit3.Clear;
edit4.Clear;
edit5.Clear;
edit6.Clear;
edit7.Clear;
edit8.Clear;
edit1.MaxLength := 12;
edit2.MaxLength := 25;
edit3.MaxLength := 40;
edit4.MaxLength := 12;
edit1.SetFocus;
end;
procedure TForm3.FormShow(Sender: TObject);
begin
bersihkan;
end;
procedure TForm3.Button1Click(Sender: TObject);
begin

edit5.Text := Edit1.Text;
edit6.Text := Edit2.Text;
edit7.Text := Edit3.Text;
edit8.Text := Edit4.Text;
end;
procedure TForm3.Button2Click(Sender: TObject);
begin
bersihkan;
end;
procedure TForm3.Button3Click(Sender: TObject);
begin
close;
end;
end.

tugas 3
Tampilan form

Penginputan data SUMBER

Penginputan SIMPAN data SUMBER

Penginputan coba lagi DATA SUMBER

Proses tutup

Source code
unit ULat3;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ExtCtrls, jpeg;
type
TForm4 = class(TForm)
Shape1: TShape;
Label1: TLabel;
GroupBox1: TGroupBox;
Label2: TLabel;
Label3: TLabel;
Label4: TLabel;
Label5: TLabel;
Label6: TLabel;
Label7: TLabel;
Edit1: TEdit;
Edit2: TEdit;
RadioGroup1: TRadioGroup;
Edit3: TEdit;
Edit4: TEdit;
ComboBox1: TComboBox;
GroupBox2: TGroupBox;
Label8: TLabel;

Label9: TLabel;
Label10: TLabel;
Label11: TLabel;
Label12: TLabel;
Label13: TLabel;
Edit5: TEdit;
Edit6: TEdit;
RadioGroup2: TRadioGroup;
Edit7: TEdit;
Edit8: TEdit;
ComboBox2: TComboBox;
Button1: TButton;
Button2: TButton;
Button3: TButton;
Label14: TLabel;
Image1: TImage;
procedure FormShow(Sender: TObject);
procedure Button1Click(Sender: TObject);
procedure Button2Click(Sender: TObject);
procedure Button3Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
procedure bersihkan;
end;
var
Form4: TForm4;
implementation
uses ULat1, ULat2, UMenuUtama, ULat4, ULat5, ULat6;
{$R *.dfm}
procedure TForm4.bersihkan;
begin
edit1.Clear;
edit2.Clear;
edit3.Clear;
Edit4.Clear;
edit5.Clear;
edit6.Clear;
edit7.Clear;
Edit8.Clear;
RadioGroup1.ItemIndex := -1;
RadioGroup2.ItemIndex := -1;
ComboBox1.ItemIndex := -1;

ComboBox2.ItemIndex :=-1;
edit1.SetFocus;
end;
procedure TForm4.FormShow(Sender: TObject);
begin
bersihkan;
end;
procedure TForm4.Button1Click(Sender: TObject);
begin
edit5.Text := Edit1.Text;
edit6.Text := Edit2.Text;
RadioGroup2.ItemIndex := RadioGroup1.ItemIndex;
edit7.Text := Edit3.Text;
edit8.Text := Edit4.Text;
ComboBox2.ItemIndex := ComboBox1.ItemIndex;
ShowMessage('hore data bisa tasalin');
end;
procedure TForm4.Button2Click(Sender: TObject);
begin
bersihkan;
end;
procedure TForm4.Button3Click(Sender: TObject);
begin
close;
end;
end.

tugas 4
Tampilan form

Hasil penjumlahan

Hasil pengurangan

Hasil perkalian

Hasil pembagian

Tombol tutup

Source code
unit ULat4;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, ActnList, StdCtrls, ExtCtrls, jpeg;

type
TForm5 = class(TForm)
Shape1: TShape;
Label1: TLabel;
GroupBox1: TGroupBox;
Label2: TLabel;
Label3: TLabel;
Edit1: TEdit;
Edit2: TEdit;
GroupBox2: TGroupBox;
Button1: TButton;
Button2: TButton;
Button3: TButton;
Button4: TButton;
GroupBox3: TGroupBox;
Label4: TLabel;
Edit3: TEdit;
ActionList1: TActionList;
bersihkan: TAction;
tambah: TAction;
kurang: TAction;
kali: TAction;
bagi: TAction;
tutup: TAction;
Button5: TButton;
Label5: TLabel;
Image1: TImage;
procedure bersihkanExecute(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure tambahExecute(Sender: TObject);
procedure kurangExecute(Sender: TObject);
procedure kaliExecute(Sender: TObject);
procedure bagiExecute(Sender: TObject);
procedure tutupExecute(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form5: TForm5;
implementation
uses ULat1, ULat2, ULat3, UMenuUtama, ULat5, ULat6;
{$R *.dfm}

procedure TForm5.bersihkanExecute(Sender: TObject);


begin
edit1.Clear;
edit2.Clear;
edit3.Clear;
groupbox1.caption := 'data nilai';
groupbox2.Caption := 'proses';
groupbox3.Caption := 'hasil';
groupbox3.Enabled := false;
edit1.SetFocus;
end;
procedure TForm5.FormShow(Sender: TObject);
begin
bersihkan.Execute;
end;
procedure TForm5.tambahExecute(Sender: TObject);
begin
edit3.Text := IntToStr(StrToInt(Edit1.Text)+ StrToInt(edit2.Text)) ;
end;
procedure TForm5.kurangExecute(Sender: TObject);
begin
edit3.Text := IntToStr(StrToInt(Edit1.Text)- StrToInt(edit2.Text)) ;
end;
procedure TForm5.kaliExecute(Sender: TObject);
begin
edit3.Text := IntToStr(StrToInt(Edit1.Text)* StrToInt(edit2.Text)) ;
end;
procedure TForm5.bagiExecute(Sender: TObject);
begin
edit3.Text := FloatToStr(StrToFloat(Edit1.Text)/StrToFloat(edit2.Text)) ;
end;
procedure TForm5.tutupExecute(Sender: TObject);
begin
close;
end;
end.

tugas 5
Tampilan form

Hasil penjumlahan

Hasil pengurangan

Hasil perkalian

Hasil pembagian

Tombol tutup

Source code
unit ULat5;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, ComCtrls, StdCtrls, ActnList, ExtCtrls, XPMan, jpeg;
type
TForm6 = class(TForm)
Shape1: TShape;
Label1: TLabel;
GroupBox1: TGroupBox;
Label3: TLabel;
Label4: TLabel;
GroupBox2: TGroupBox;
Button1: TButton;
Button2: TButton;
Button3: TButton;
Button4: TButton;
GroupBox3: TGroupBox;
Label5: TLabel;
ActionList1: TActionList;
bersihkan: TAction;
tambah: TAction;
kurang: TAction;
kali: TAction;
bagi: TAction;
tutup: TAction;
Button5: TButton;
Label2: TLabel;
Label6: TLabel;
Label7: TLabel;
Label8: TLabel;
Edit1: TEdit;
Edit2: TEdit;
Edit3: TEdit;
Edit4: TEdit;
Edit5: TEdit;
Edit6: TEdit;
Edit7: TEdit;
ProgressBar1: TProgressBar;
proses: TAction;
XPManifest1: TXPManifest;
Timer1: TTimer;
Label9: TLabel;
Label10: TLabel;

Label11: TLabel;
Image1: TImage;
procedure bersihkanExecute(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure prosesExecute(Sender: TObject);
procedure Timer1Timer(Sender: TObject);
procedure tambahExecute(Sender: TObject);
procedure kurangExecute(Sender: TObject);
procedure kaliExecute(Sender: TObject);
procedure bagiExecute(Sender: TObject);
procedure tutupExecute(Sender: TObject);
// procedure kurangExecute(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form6: TForm6;
implementation
uses ULat1, ULat2, ULat3, ULat4, UMenuUtama, ULat6;
{$R *.dfm}
procedure TForm6.bersihkanExecute(Sender: TObject);
begin
Edit1.Clear;
Edit2.Clear;
Edit3.Clear;
Edit4.Clear;
Edit5.Clear;
Edit6.Clear;
Edit7.Clear;
GroupBox1.Caption := 'data nilai';
GroupBox2.Caption := 'proses';
GroupBox3.Caption := 'hasil';
GroupBox3.Enabled := False;
ProgressBar1.Position := 0;
Edit1.SetFocus;
Timer1.Enabled := False;
end;

procedure TForm6.FormShow(Sender: TObject);

begin
bersihkan.Execute;
end;
procedure TForm6.prosesExecute(Sender: TObject);
var a :byte;
begin
for a := 1 to 100 do
begin
ProgressBar1.Position:= a;
Sleep(20);
end;
end;
procedure TForm6.Timer1Timer(Sender: TObject);
begin
Timer1.Enabled := False;

end;
procedure TForm6.tambahExecute(Sender: TObject);
begin
if ((Edit1.Text <>'')and (Edit2.Text <>'')and (Edit3.Text <>'')and (Edit4.Text <>'')and (Edit5.Text
<>'')and (Edit6.Text <>'')) then
begin
proses.Execute;
try
Edit7.Text := IntToStr(StrToInt(Edit1.Text)+ StrToInt(Edit2.Text)+ StrToInt(Edit3.Text)+
StrToInt(Edit4.Text)+ StrToInt(Edit5.Text)+ StrToInt(Edit6.Text));
Timer1.Enabled := True;
GroupBox3.Caption := 'hasil
penjumlahan'+Edit1.Text+Edit2.Text+Edit3.Text+Edit4.Text+Edit5.Text+Edit6.Text+'adalah';
except
on EConvertError do
begin
ShowMessage('terjadi kesalahan penginputan mohon cek kembali');
bersihkan.Execute;
end;
end;

end
else
begin
ShowMessage('data pada nilai 1 sampai 6 tidak boleh kosong');
Edit1.SetFocus;
end;

end;

procedure TForm6.kurangExecute(Sender: TObject);


begin
if ((Edit1.Text <>'')and (Edit2.Text <>'')and (Edit3.Text <>'')and (Edit4.Text <>'')and (Edit5.Text
<>'')and (Edit6.Text <>''))then
begin
proses.Execute;
try
Edit7.Text:= IntToStr(strtoint(Edit1.Text)- strtoint(Edit2.Text)-strtoint(Edit3.Text)strtoint(Edit4.Text)-strtoint(Edit5.Text)-strtoint(Edit6.Text));
Timer1.Enabled := True;
GroupBox3.Caption := 'hasil
pengurangan'+Edit1.Text+Edit2.Text+Edit3.Text+Edit4.Text+Edit5.Text+Edit6.Text;
except
on EConvertError do
begin
ShowMessage('terjadi kesalahan penginputan mohon cek kembali');
bersihkan.Execute;
end;
end;
end
else
begin
ShowMessage('data pada nilai 1 sampai 6 tidak boleh kosong');
Edit1.SetFocus;
end;
end;

procedure TForm6.kaliExecute(Sender: TObject);


begin
if ((Edit1.Text <>'')and (Edit2.Text <>'')and (Edit3.Text <>'')and (Edit4.Text <>'')and (Edit5.Text
<>'')and (Edit6.Text <>''))then
begin
proses.Execute;
try
Edit7.Text:= IntToStr(strtoint(Edit1.Text)* strtoint(Edit2.Text)* strtoint(Edit3.Text)*
strtoint(Edit4.Text)* strtoint(Edit5.Text)* strtoint(Edit6.Text));
Timer1.Enabled := True;
GroupBox3.Caption := 'hasil
perkalian'+Edit1.Text+Edit2.Text+Edit3.Text+Edit4.Text+Edit5.Text+Edit6.Text;
except

on EConvertError do
begin
ShowMessage('terjadi kesalahan penginputan mohon cek kembali');
bersihkan.Execute;
end;
end;
end
else
begin
ShowMessage('data pada nilai 1 sampai 6 tidak boleh kosong');
Edit1.SetFocus;
end;
end;

procedure TForm6.bagiExecute(Sender: TObject);


begin
if ((Edit1.Text <>'')and (Edit2.Text <>'')and (Edit3.Text <>'')and (Edit4.Text <>'')and (Edit5.Text
<>'')and (Edit6.Text <>''))then
begin
proses.Execute;
try
Edit7.Text:= FloatToStr(StrToFloat(Edit1.Text)/
StrToFloat(Edit2.Text)/StrToFloat(Edit3.Text)/StrToFloat(Edit4.Text)/StrToFloat(Edit5.Text)/St
rToFloat(Edit6.Text));
Timer1.Enabled := True;
GroupBox3.Caption := 'hasil
pembagian'+Edit1.Text+Edit2.Text+Edit3.Text+Edit4.Text+Edit5.Text+Edit6.Text;
except
on EConvertError do
begin
ShowMessage('terjadi kesalahan penginputan mohon cek kembali');
bersihkan.Execute;
end;
end;
end
else
begin
ShowMessage('data pada nilai 1 sampai 6 tidak boleh kosong');
Edit1.SetFocus;
end;
end;

procedure TForm6.tutupExecute(Sender: TObject);


begin
Close;
end;
end.

Tugas 6

Tampilan Desain Form

Penginputan data pada no induk harus berupa angka, apabila huruf maka akan timbul pesan
Seperti pada gambar di bawah ini

Penginputan data pada nama mahasiswa harus berupa huruf, apabila angka maka akan timbul
pesan
Seperti pada gambar di bawah ini

Penginputan data secara keseluruhan jika LULUS

Penginputan data secara keseluruhan jika TIDAK LULUS

Penginputan data jika BATAL akan menampilkan gambar di bawah ini

Proses batal akan menampilkan hasil pada gambar di bawah ini

penginputan data jika menutup pada gambar di bawah ini

Proses menutup program pada gambar di bawah ini

TAMPILAN SOURCE CODE

unit Unit1latihan6;

interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, XPMan, ComCtrls, ActnList, StdCtrls, Buttons, ExtCtrls, jpeg;
type
TForm1 = class(TForm)
Shape1: TShape;
Label1: TLabel;
Label2: TLabel;
GroupBox1: TGroupBox;
Edit1: TEdit;
Edit2: TEdit;
RadioGroup1: TRadioGroup;
Edit3: TEdit;
Edit4: TEdit;
GroupBox3: TGroupBox;
BitBtn1: TBitBtn;
BitBtn2: TBitBtn;
BitBtn3: TBitBtn;
ActionList1: TActionList;
ProgressBar1: TProgressBar;
XPManifest1: TXPManifest;
Bersihkan: TAction;
Proses: TAction;
Hasil: TAction;
Batal: TAction;
Tutup: TAction;
GroupBox2: TGroupBox;
Label4: TLabel;
Label5: TLabel;
Label6: TLabel;
Label7: TLabel;
Label8: TLabel;
Label9: TLabel;
Label10: TLabel;
Label11: TLabel;
Label12: TLabel;
Label13: TLabel;
Edit5: TEdit;

Edit6: TEdit;
Edit7: TEdit;
Edit8: TEdit;
Edit9: TEdit;
Edit10: TEdit;
Label14: TLabel;
Label15: TLabel;
Label16: TLabel;
Label17: TLabel;
Label18: TLabel;
Label19: TLabel;
Label20: TLabel;
Label21: TLabel;
Edit11: TEdit;
Edit12: TEdit;
Edit13: TEdit;
Edit14: TEdit;
Edit15: TEdit;
Edit16: TEdit;
Edit17: TEdit;
Edit18: TEdit;
Edit19: TEdit;
Label23: TLabel;
Edit20: TEdit;
Edit21: TEdit;
Edit22: TEdit;
Edit23: TEdit;
Edit24: TEdit;
Edit25: TEdit;
label22: TLabel;
Label30: TLabel;
Label24: TLabel;
Label25: TLabel;
Label26: TLabel;
Label27: TLabel;
Label28: TLabel;
Label29: TLabel;
Image2: TImage;
Label3: TLabel;
procedure BersihkanExecute(Sender: TObject);
procedure FormShow(Sender: TObject);
procedure ProsesExecute(Sender: TObject);
procedure HasilExecute(Sender: TObject);
procedure BatalExecute(Sender: TObject);
procedure TutupExecute(Sender: TObject);
procedure Edit1KeyPress(Sender: TObject; var Key: Char);
procedure Edit2KeyPress(Sender: TObject; var Key: Char);
procedure Edit3KeyPress(Sender: TObject; var Key: Char);

procedure Edit4KeyPress(Sender: TObject; var Key: Char);


procedure Edit5KeyPress(Sender: TObject; var Key: Char);
procedure Edit6KeyPress(Sender: TObject; var Key: Char);
procedure Edit7KeyPress(Sender: TObject; var Key: Char);
procedure Edit8KeyPress(Sender: TObject; var Key: Char);
procedure Edit9KeyPress(Sender: TObject; var Key: Char);
procedure Edit10KeyPress(Sender: TObject; var Key: Char);
procedure BitBtn3KeyPress(Sender: TObject; var Key: Char);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
implementation
uses Math;
{$R *.dfm}

procedure TForm1.BersihkanExecute(Sender: TObject);


var i :integer;
begin
with form1 do
begin
for i := 0 to componentcount-1 do
if (components[i] is TEdit) then
begin
(components[i] as TEdit).Text := '';
end;
end;
GroupBox1.Caption := '';
GroupBox2.Caption := '';
GroupBox3.Caption := '';
radiogroup1.ItemIndex := -1;
progressbar1.position := 0;
label30.caption := '-';
GroupBox2.Enabled := false;
edit1.setfocus;
end;

procedure TForm1.FormShow(Sender: TObject);

begin
bersihkan.Execute;
end;
procedure TForm1.ProsesExecute(Sender: TObject);
var a : byte;
begin
for a := 1 to 100 do
begin
ProgressBar1.Position := a;
sleep(20);
end;
end;
procedure TForm1.HasilExecute(Sender: TObject);
begin
Proses.Execute;
Edit11.Text :=Edit1.Text;
Edit12.Text :=Edit2.Text;
Edit13.Text :=RadioGroup1.Items[RadioGroup1.itemindex];
Edit14.Text :=Edit3.Text;
Edit15.Text :=Edit4.Text;
Edit16.Text :=Edit5.Text;
Edit17.Text :=Edit6.Text;
Edit18.Text :=Edit7.Text;
Edit19.Text :=Edit8.Text;
Edit20.Text := FloatToStr(StrToFloat(Edit19.Text)+StrToFloat(Edit10.Text)+StrToFloat(Edit9.Text)/2);
Edit21.Text := FloatToStr(StrToFloat(Edit19.Text)+StrToFloat(Edit10.Text)+StrToFloat(Edit9.Text));
Edit22.Text := FloatToStr(StrToFloat(Edit21.Text)/2);
Edit23.Text := FloatToStr(StrToFloat(Edit19.Text)+StrToFloat(Edit10.Text)+StrToFloat(Edit9.Text)/2);
Edit24.Text := FloatToStr(StrToFloat(Edit23.Text)/3);
if StrToFloat(Edit24.Text) >= 80 then Edit25.Text := 'A'
else if StrToFloat(Edit24.Text) >= 70 then Edit25.Text := 'B'
else if StrToFloat(Edit24.Text) >= 60 then Edit25.Text := 'C'
else if StrToFloat(Edit24.Text) >= 50 then Edit25.Text := 'D'
else Edit25.Text := 'E';
if Edit25.Text = 'E' then
begin
Label30.Font.Color := clRed;
Label30.Caption := 'TIDAK LULUS';
end
else
begin
Label30.Font.Color := clBlue;
Label30.Caption := 'LULUS';
end;
end;

procedure TForm1.BatalExecute(Sender: TObject);


begin
Bersihkan.Execute;
end;
procedure TForm1.TutupExecute(Sender: TObject);
begin
if(Application.MessageBox('Anda yakin ingin
keluar','125403130162)',MB_YESNO+MB_ICONQUESTION)=idyes)then close;
bersihkan.Execute;
begin
if MessageDlg('Terjadi Kesalahan Mohon Cek Kembali',mtConfirmation,mbOKCancel,0)=idcancel
then Close;
Bersihkan.Execute;
end;
end;
procedure TForm1.Edit1KeyPress(Sender: TObject; var Key: Char);
begin
if not(key in[#8,'0'..'9'])then begin
ShowMessage('data yang dimasukan hanya berupa angka ');
key:=#0;
end;
end;
procedure TForm1.Edit2KeyPress(Sender: TObject; var Key: Char);
begin
if not(key in[#8,'a'..'z','A'..'Z'])then begin
ShowMessage('data yang dimasukan hanya berupa huruf');
key:=#0;
end;
end;

procedure TForm1.Edit3KeyPress(Sender: TObject; var Key: Char);


begin
if not(key in[#8,'0'..'9'])then begin
ShowMessage('data yang dimasukan hanya berupa angka');
key:=#0;
end;
end;
procedure TForm1.Edit4KeyPress(Sender: TObject; var Key: Char);
begin

if not(key in[#8,'0'..'9'])then begin


ShowMessage('data yang dimasukan hanya berupa angka');
key:=#0;
end;
end;
procedure TForm1.Edit5KeyPress(Sender: TObject; var Key: Char);
begin
if not(key in[#8,'0'..'9'])then begin
ShowMessage('data yang dimasukan hanya berupa angka');
key:=#0;
end;
end;
procedure TForm1.Edit6KeyPress(Sender: TObject; var Key: Char);
begin
if not(key in[#8,'0'..'9'])then begin
ShowMessage('data yang dimasukan hanya berupa angka');
key:=#0;
end;
end;
procedure TForm1.Edit7KeyPress(Sender: TObject; var Key: Char);
begin
if not(key in[#8,'0'..'9'])then begin
ShowMessage('data yang dimasukan hanya berupa angka');
key:=#0;
end;
end;
procedure TForm1.Edit8KeyPress(Sender: TObject; var Key: Char);
begin
if not(key in[#8,'0'..'9'])then begin
ShowMessage('data yang dimasukan hanya berupa angka');
key:=#0;
end;
end;
procedure TForm1.Edit9KeyPress(Sender: TObject; var Key: Char);
begin
if not(key in[#8,'0'..'9'])then begin
ShowMessage('data yang dimasukan hanya berupa angka');
key:=#0;
end;
end;
procedure TForm1.Edit10KeyPress(Sender: TObject; var Key: Char);
begin

if not(key in[#8,'0'..'9'])then begin


ShowMessage('data yang dimasukan hanya berupa angka');
key:=#0;
end;
end;
procedure TForm1.BitBtn3KeyPress(Sender: TObject; var Key: Char);
begin
if(Application.MessageBox('yakin mau
keluar','125403130162)',MB_YESNO+MB_ICONQUESTION)=idyes)then close;
end;
end.