PENDAHULUAN
1.1 Tujuan
Tujuan umum dari pembuatan laporan ini adalah :
a. Sebagai salah satu tugas akhir mata kuliah Program Komputer
Visual Basic
1.2 Manfaat
Manfaat dari penulisan tugas akhir visual basic ini adalah:
a. Mengetahui langkah-langkah proses pembuatan program
perhitungan luas macam macam bangun datar : lingkaran, segi
empat, segi tiga, trapesium.
b. Mengetahui langkah-langkah proses pembuatan program
perhitungan volume bangun ruang tabung
1
c. Mengetahui langkah-langkah proses pembuatan program
perhitungan konversi sudut.
d. Mengetahui langkah-langkah proses pembuatan program
perhitungan konversi suhu
e. Mengetahui langkah-langkah proses pembuatan program
perhitungan perencaan poros pejal
f. Mengetahui langkah langkah proses pembuatan program
aplikasi multiform.
2
BAB II
DASAR TEORI
3
2.2. Tujuan
Tujuan umum dari pembuatan laporan ini adalah :
b. Sebagai salah satu tugas akhir mata kuliah Visual Basic
2.3. Manfaat
Manfaat dari penulisan tugas akhir visual basic ini adalah
g. Mengetahui langkah-langkah proses pembuatan program
perhitungan luas macam macam bangun datar : lingkaran, segi
empat, segi tiga, trapesium.
h. Mengetahui langkah-langkah proses pembuatan program
perhitungan volume bangun ruang tabung
i. Mengetahui langkah-langkah proses pembuatan program
perhitungan konversi sudut.
j. Mengetahui langkah-langkah proses pembuatan program
perhitungan konversi suhu
4
k. Mengetahui langkah-langkah proses pembuatan program
perhitungan perencaan poros pejal
l. Mengetahui langkah langkah proses pembuatan program
aplikasi multiform.
5
BAB III
DATA DAN PEMBAHASAN
3.1. TUGAS 1
Tugas 1 dilaksanan pada tanggal 28 september 2016, dengan topik
perkuliahan yaitu pembuatan program dan aplikasi menggunakaan Visual
Basic 6.0. Pembuatan program dan aplikasi yaitu meliputi perhitungan
luas macam macam bangun datar seperti lingkaran, segi empat, segi
tiga, trapesium dan perhitungan volume bangun ruang tabung.
a. Desain form
b. Membuat property
Objek Property Nilai
Label 1 Caption Program menghitung luas
lingkaran
Label 2 Caption Oleh : Faris Putra Irawan,
No:08, Kelas : ME3G
Label 3 Caption Dibuat: 29-September-2016
Label 4 Caption Diameter
Label 5 Caption (mm)
Label 6 Caption Luas
6
Label 7 Caption (mm^2)
Text1 Text Kosongkan
Text 2 Text Kosongkan
c. Menulis program
7
d. Hasil setelah dijalankan
8
b. Membuat property
Objek Property Nilai
Label 1 Caption Program menghitung luas
segiempat
Label 2 Caption Oleh : Faris Putra Irawan,
No:08, Kelas : ME3G
Label 3 Caption Dibuat: 29-September-2016
Label 4 Caption Panjang
Label 5 Caption (mm)
Label 6 Caption Lebar
Label 7 Caption (Mm)
Label 8 Caption Luas Segiempat
Label 9 Caption (mm^2)
Text1 Text Kosongkan
Text 2 Text Kosongkan
Text 3 Text Kosongkan
c. Menulis program
9
Text3 = Val(Text1) * Val(Text2)
End Sub
b. Membuat property
10
Objek Property Nilai
Label 1 Caption Program menghitung luas
segitiga
Label 2 Caption Oleh : Faris Putra Irawan,
No: 08, Kelas : ME3G
Label 3 Caption Dibuat: 29-09-2016
Label 4 Caption Alas
Label 5 Caption (mm)
Label 6 Caption Tinggi
Label 7 Caption (mm)
Label 8 Caption Luas Segitiga
Label 9 Caption (mm^2)
Text 1 Text Kosongkan
Text 2 Text Kosongkan
Text 3 Text Kosongkan
c. Menulis program
11
Private Sub Text2_Change()
Text3 = Val(Text1) * Val(Text2) * 1 / 2
End Sub
Private Sub Text3_Change()
Text3 = Val(Text1) * Val(Text2) * 1 / 2
End Sub
12
b. Membuat property
Objek Property Nilai
Label 1 Caption Program menghitung luas
Trapesium
Label 2 Caption Oleh : Faris Putra Irawan,
No:08, Kelas: ME36
Label 3 Caption Dibuat: 29-September-2016
Label 4 Caption Panjang sisi sejajar AB
Label 5 Caption (mm)
Label 6 Caption Panjang sisi sejajar CD
Label 7 Caption (mm)
Label 8 Caption Tinggi
Label 9 Caption (Mm)
Label 10 Caption Luas trapesium
Label 11 Caption (Mm^2)
Text 1 Text Kosongkan
Text 2 Text Kosongkan
Text 3 Text Kosongkan
Text 4 Text Kosongkan
c. Menulis program
13
End Sub
Private Sub Text3_Change()
Text4 = (Val(Text1) + Val(Text2)) * 1 / 2 * Val(Text3)
End Sub
Private Sub Text4_Change()
Text4 = (Val(Text1) + Val(Text2)) * 1 / 2 * Val(Text3)
End Sub
3.2 TUGAS 2
Tugas 2 dilaksanan pada tanggal 05 Oktober 2016, dengan topik
perkuliahan yaitu pembuatan program dan aplikasi menggunakaan Visual
Basic 6.0. Pembuatan program dan aplikasi yaitu meliputi perhitungan
luas macam macam bangun datar seperti lingkaran, segi empat, segi
tiga, trapesium dan perhitungan volume bangun ruang tabung dengan
penambahan perintah commandbutton proses hitung.
14
a. Desain form
b. Membuat property
Objek Property Nilai
Label 1 Caption Program menghitung luas
lingkaran
Label 2 Caption Oleh : Faris Putra Irawan,
No:08, Kelas : ME3G
Label 3 Caption Dibuat: 05-Oktober-2016
Label 4 Caption Diameter
Label 5 Caption mm
Label 6 Caption Luas
Label 7 Caption mm^2
Text1 Text Kosongkan
Text 2 Text kosongkan
Command 1 Caption Proses hitung
c. Menulis program
15
Berikut ini listing programnya:
Private Sub Command1_Click()
Text2 = 3.14 * Val(Text1) ^ 2
End Sub
Private Sub Text1_Change()
End Sub
16
d. Hasil setelah dijalankan
b. Membuat property
Objek Property Nilai
Label 1 Caption Program menghitung luas
segiempat
Label 2 Caption Oleh : Faris Putra Irawan,
17
No: 08, Kelas: ME3G
Label 3 Caption Dibuat: 05-Oktober-2016
Label 4 Caption Panjang
Label 5 Caption mm
Label 6 Caption Lebar
Label 7 Caption mm
Label 8 Caption Luas
Label 9 Caption mm^2
Text1 Text Kosongkan
Text 2 Text kosongkan
Text 3 Text Kosongkan
Command 1 Caption Proses hitung
c. Menulis program
18
d. Hasil setelah dijalankan
19
b. Membuat property
Objek Property Nilai
Label 1 Caption Program menghitung luas
segitiga
Label 2 Caption Oleh : Faris Putra Irawan
Label 3 Caption Dibuat: 05-Oktober-2016
Label 4 Caption Alas
Label 5 Caption (mm)
Label 6 Caption Tinggi
Label 7 Caption (mm)
Label 8 Caption Luas Segitiga
Label 9 Caption (mm^2)
Text 1 Text Kosongkan
Text 2 Text Kosongkan
Text 3 Text Kosongkan
Command 1 Caption Proses hitung
c. Menulis program
20
Tekan proses.
21
b. Membuat property
Objek Property Nilai
Label 1 Caption Program menghitung luas
Trapesium
Label 2 Caption Oleh : Faris Putra Irawan,
No: 08, Kelas : ME3G
Label 3 Caption Dibuat: 05-Oktober-2016
Label 4 Caption Panjang sisi sejajar AB
Label 5 Caption (mm)
Label 6 Caption Panjang sisi sejajar CD
Label 7 Caption (mm)
Label 8 Caption Tinggi
Label 9 Caption (mm)
Label 10 Caption Luas trapesium
Label 11 Caption (mm^2)
Text1 Text Kosongkan
Text 2 Text Kosongkan
Text 3 Text Kosongkan
Text 4 Text Kosongkan
Command 1 Caption Proses hitung
c. Menulis program
22
Text4 = (Val(Text1) + Val(Text2)) * 1 / 2 * Val(Text3)
End Sub
3.3 TUGAS 3
Tugas 3 dilaksanan pada tanggal 12 Oktober 2016, dengan topik
perkuliahan yaitu pembuatan program dan aplikasi menggunakaan Visual
Basic 6.0. Pembuatan program dan aplikasi yaitu meliputi perhitungan
luas macam macam bangun datar seperti lingkaran, segi empat, segi
tiga, trapesium dan perhitungan volume bangun ruang tabung dengan
penambahan perintah commandbutton proses hitung, hitung ulang dan
keluar.
3.3.1 Program Perhitungan Luas Lingkaran
23
Langkah-langkah pembuatan program & aplikasi yaitu sebagai berikut:
a. Desain form
b. Membuat property
Objek Property Nilai
Label 1 Caption Program menghitung luas
lingkaran
Label 2 Caption Oleh : Faris Putra Irawan,
No:08, Kelas : ME3G
Label 3 Caption Dibuat: 12-Oktober-2016
Label 4 Caption Diameter
Label 5 Caption Mm
Label 6 Caption Luas
Label 7 Caption mm^2
Text1 Text Kosongkan
Text 2 Text Kosongkan
Command 1 Caption Proses hitung
Command 2 Caption Hitung ulang
Command 3 Caption Keluar
24
c. Menulis program
25
d. Hasil setelah dijalankan
b. Membuat property
Objek Property Nilai
26
Label 1 Caption Program menghitung luas
segiempat
Label 2 Caption Oleh : Faris Putra Irawan,
No:08, Kelas : ME3G
Label 3 Caption Dibuat: 05-Oktober-2016
Label 4 Caption Panjang
Label 5 Caption Mm
Label 6 Caption Lebar
Label 7 Caption Mm
Label 8 Caption Luas
Label 9 Caption mm^2
Text 1 Text Kosongkan
Text 2 Text kosongkan
Text 3 Text Kosongkan
Command 1 Caption Proses hitung
Command 2 Caption Hitung ulang
Command 2 Caption Keluar
c. Menulis program
27
Text3 = " "
Text1.SetFocus
End Sub
Private Sub Command3_Click()
End
End Sub
28
b. Membuat property
Objek Property Nilai
Label 1 Caption Program menghitung luas
segitiga
Label 2 Caption Oleh : Faris Putra Irawan,
No:08, Kelas : ME3G
Label 3 Caption Dibuat: 12-Oktober-2016
Label 4 Caption Alas
Label 5 Caption mm
Label 6 Caption Tinggi
Label 7 Caption mm
Label 8 Caption Luas Segitiga
Label 9 Caption mm^2
Text 1 Text Kosongkan
Text 2 Text Kosongkan
Text 3 Text Kosongkan
Command 1 Caption Proses hitung
Command 2 Caption Hitung ulang
Command 3 Caption Keluar
29
c. Menulis program
30
d. Hasil setelah dijalankan
31
b. Membuat property
Objek Property Nilai
Label 1 Caption Program menghitung luas
Trapesium
Label 2 Caption Oleh : Faris Putra Irawan
Label 3 Caption Dibuat: 12-Oktober-2016
Label 4 Caption Panjang sisi sejajar AB
Label 5 Caption mm
Label 6 Caption Panjang sisi sejajar CD
Label 7 Caption mm
Label 8 Caption Tinggi
Label 9 Caption mm
Label 10 Caption Luas
Label 11 Caption mm^2
Text1 Text Kosongkan
Text 2 Text Kosongkan
Text 3 Text Kosongkan
Text 4 Text Kosongkan
Command 1 Caption Proses hitung
Command 2 Caption Hitung ulang
Command 3 Caption Keluar
c. Menulis program
32
Private Sub Command2_Click()
Text1 = ""
Text2 = ""
Text3 = ""
Text4 = ""
Text1.SetFocus
End Sub
Private Sub Command3_Click()
End
End Sub
33
3.4 TUGAS 4
Tugas di laksanakan pada tanggal 19 Oktober 2016 dengan topik
perkuliahan yaitu pembuatan program dan aplikasi menggunakaan Visual
Basic 6.0. Pembuatan program yaitu aplikasi multiform, yang berisi
perhitungan luas lingkaran, luas segiempat, luas segitiga, luas trapesium
dan volume tabung.
Langkah-langkah pembuatan program & aplikasi yaitu sebagai berikut:
a. Desain form
Project form1
Project form2
Project form3
34
Project Form4
35
Project Form5
b. Membuat property
Form 1 berisi :
Objek Property Nilai
Label 1 Caption Program perhitungan
dengan rumus - rumus
sederhana
Label 2 Caption Oleh : Faris Putra Irawan,
No:08, Kelas: ME3G
Label 3 Caption Dibuat : 19-Oktober- 2016
Command1 Caption Lingkaran
Command2 Caption Persegi panjang
Command3 Caption Segi Tiga
Command4 Caption Trapesium
Command5 Caption Keluar
Form 2 berisi :
Objek Property Nilai
Label 1 Caption Program menghitung luas
lingkaran
Label 2 Caption Disusun oleh : Faris Putra
Irawan, No:08, Kelas:
ME3G
Label 3 Caption Dibuat : 19-10- 2016
Label 4 Caption Diameter
Label 5 Caption mm^2
Label 6 Caption Luas
Label 7 Caption mm^2
36
Text1 Text Kosongan
Command1 Caption Proses Hitung
Command2 Caption Hitung Ulang
Command3 Caption Kembali
37
Command2 Caption Hitung Ulang
Command3 Caption Kembali
c. Menulis program
Form 1
38
Berikut ini listing programnya:
Private Sub Command1_Click()
LINGKARAN.Show
Menu.Hide
End Sub
Private Sub Command2_Click()
PERSEGIPANJANG.Show
Menu.Hide
End Sub
Private Sub Command3_Click()
SEGITIGA.Show
Menu.Hide
End Sub
Private Sub Command4_Click()
TRAPESIUM.Show
Menu.Hide
End Sub
Private Sub Command5_Click()
End
End Sub
39
Form 2
40
Berikut ini listing programnya:
Private Sub Command1_Click()
Textluas = Val(Textpanjang) * Val (Textlebar)
End Sub
Private Sub Command2_Click()
Textpanjang = " "
Textlebar = " "
Textluas =
Textpanjang =
End Sub
Private Sub Command3_Click()
Menu.Show
PERSEGIPANJANG.Hide
End Sub
Form4
41
Private Sub Command2_Click()
Textalas = " "
Texttinggi = " "
Textluas =
Textalas.SetFocus
End Sub
Private Sub Command3_Click()
Menu.Show
SEGITIGA.HIde
End Sub
Form5
42
Textluas = (Val(Textsisi1) + Val (Textsisi2)) * 1 / 2 * Val(Texttinggi)
End Sub
Private Sub Command2_Click()
Textsisi1 = " "
Textsisi2 = " "
Texttinggi =
Textluas =
Textsisi1.SetFocus
End Sub
Private Sub Command3_Click()
Menu.Show
TRAPESIUM.Hide
End Sub
43
Aplikasi berjalan dan di input dengan data
44
3.5 TUGAS 5
Tugas di laksanakan pada tanggal 3 November 2016 dengan topik
perkuliahan yaitu pembuatan program dan aplikasi menggunakaan Visual
Basic 6.0. Pembuatan program yaitu aplikasi Konversi sudut.
Langkah-langkah pembuatan program & aplikasi yaitu :
45
a. Desain form
b. Membuat property
Objek Property Nilai
Label 1 Caption Tugas 5 : Konversi Sudut
46
c. Menulis program
47
Text5 = ""
Text1.SetFocus
End Sub
Private Sub Command6_Click()
End
End Sub
3.6 TUGAS 6
Tugas di lakukan pada tanggal 3 November 2016 dengan topik
perkuliahan yaitu pembuatan program dan aplikasi menggunakaan Visual
Basic 6.0. Pembuatan program yaitu aplikasi Konversi suhu.
Langkah-langkah pembuatan program & aplikasi yaitu
48
a. Desain form
b. Membuat property
Objek Property Nilai
Label 1 Caption Tugas 6 : Konversi Suhu
49
Command5 Caption Keluar
c. Menulis program
50
Private Sub Command5_Click()
End
End Sub
Kemudian jalankan dengan pilih menu Run | Start atau tekan F5
pada keyboard.
Tekan proses.
Tugas ini merupakan tugas akhir dari mata kuliah Program Komputer.
Pembuatan program dan aplikasi menggunakaan Visual Basic 6.0.
Pembuatan program yaitu aplikasi multiform, yang berisi perhitungan
poros secara lengkap.
Langkah-langkah pembuatan program & aplikasi yaitu
a. Desain form
Project form1
51
Project form2
Project form3
52
Project Form4
53
Project Form5
Project Form6
b. Membuat property
Form 1 berisi :
Objek Property Nilai
Label 1 Caption Perhitungan Pada Siklus
Diesel Atau Pada Siklus
Tekanan Konstan
Label 2 Caption Nama : Faris Putra Irawan
54
Label 3 Caption Kelas : Me-3G
Label 4 Caption Nim : 3.21.14.3.10
Image 1 Image Diagram P-V
Image 2 Image Diagram T-S
Command1 Caption Mencari Volume Tiap Titik
Pada Diagram P-V (Gambar 1)
Command2 Caption Mencari Tekanan Tiap Titik
Pada Diagram P-V (Gambar 1)
Command3 caption Mencari Temperatur Tiap Titik
Pada Diagram T-S (Gambar 2)
Form 2 berisi
Objek Property Nilai
Label 1 Caption Mencari Volume Tiap Titik
Pada Diagram P-V (Gambar 1)
Label 2 Caption Diameter
Label 3 Caption (mm)
Label 4 Caption Panjang Langkah
Label 5 Caption (mm)
Label 6 Caption Rasio Kompresi
Label 7 Caption % Volume Stroke
Label 8 Caption (mm^3)
Label 9 Caption (mm^3)
Label 10 Caption (mm^3)
Label 11 Caption (mm^3)
Label 12 Caption (mm^3)
Text 1 Text Kosongkan
Text 2 Text Kosongkan
Text 3 Text Kosongkan
Text 3 Text Kosongkan
Text 3 Text Kosongkan
Text 4 Text Kosongkan
Text 5 Text Kosongkan
Text 6 Text Kosongkan
Text 7 Text Kosongkan
Text 8 Text Kosongkan
Text 9 Text Kosongkan
Command1 Caption Volume Stroke
Command2 Caption Volume 2 (V2)
Command3 Caption Volume 1 (V1)
Command 4 Caption Volume 3 (V3)
Command 5 Caption Volume 4 (V4)
Command 6 Caption Hitung Ulang
Command 7 Caption Kembali ke Menu Pilihan
55
Project form3 berisi :
Objek Property Nilai
Label 1 Caption Program Mencari Tekanan
Tiap Titik pada Diagram P-V
(Gambar 1)
Label 2 Caption Tekanan 1 (P1)
Label 3 Caption Volume 1 (V1)
Label 4 Caption Volume 2 (V2)
Label 5 Caption Volume 3 (V3)
Label 6 Caption Volume 4 (V4)
Label 7 Caption (N/mm^2)
Label 8 Caption (mm^3)
Label 9 Caption (mm^3)
Label 10 Caption (mm^3)
Label 11 Caption (mm^3)
Label 12 Caption (N/mm^2)
Label 13 Caption (N/mm^2)
Label 14 Caption (N/mm^2)
Command 1 Caption Tekanan 2 (P2)
Command 2 Caption Tekanan 3 (P3)
Command 3 Caption Tekanan 4 (P4)
Command 4 Caption Hitung Ulang
Command 5 Caption Kembali ke Menu Pilihan
56
Command 4 Caption Hitung Ulang
Command 5 Caption Kembali ke Menu Pilihan
57
Label 12 Caption Work/Cycle
Label 13 Caption (J/Cycle)
Command 1 Caption Rasio Kompresi (r)
Command 2 Caption Cut off Ratio
Command 3 Caption Volume Stroke (Vs)
Command 4 Caption Tekanan Efektif Rata2 (Pm)
Command 5 Caption Hitung
Command 6 Caption Hitung Ulang
Command 7 Caption Kembali Ke Menu Pilihan
c. Menulis program
Form 1
58
End Sub
Private Sub Command3_Click()
Temperatur.Show
menu. Hide
End Sub
Private Sub Command4_Click()
efisiensi.Show
menu. Hide
End Sub
Private Sub Command5_Click()
kerja.Show
menu. Hide
End Sub
Private Sub Command6_Click()
end
End Sub
Form 2
59
Berikut ini listing programnya
Private Sub Command1_Click()
Vs = 22 / 7 * Val(D ^ 2) * Val (L)
End Sub
Private Sub Command2_Click()
V2 = (Val(Vs) / (Val(r) 1))
End Sub
Private Sub Command3_Click()
V1 = Val (Vs) + Val (V2)
End Sub
Private Sub Command4_Click()
V3 = Val (PERSEN) + Val (V2)
End Sub
Private Sub Command5_Click()
V4 = Val (V1)
End Sub
Private Sub Command6_Click()
Vs = " "
V2 = " "
V3 =
V4 =
End Sub
Private Sub Command7_Click()
menu.Show
End Sub
Form 3
60
Berikut ini listing programnya:
Private Sub Command1_Click()
p2 = Val(P1) * (Val(V1) / Val (V2)) ^ 1.4
End Sub
Private Sub Command2_Click()
p3 = Val(p2)
End Sub
Private Sub Command3_Click()
p4 = Val(p3) * (Val(V3) / Val (V4)) ^ 1.4
End Sub
Private Sub Command4_Click()
P1 =
V1 =
V2 =
V3 =
V4 =
p2 =
p3 =
61
p4 =
P1.SetFocus
End Sub
Private Sub Command5_Click()
menu.Show
End Sub
Form4
62
V1 =
V2 =
V3 =
V4 =
T2 =
T3 =
T4 =
T1.SetFocus
End Sub
Private Sub Command5_Click()
menu.Show
End Sub
Form5
63
End Sub
Private Sub Command3_Click()
EFISIEN = (Val(Q1) Val(Q2)) / Val(Q1)
End Sub
Private Sub Command4_Click()
T1 =
T2 =
T3 =
T4 =
CP =
CV =
MU =
Q1 =
Q2 =
EFISIEN =
T1.SetFocus
End Sub
Private Sub Command5_Click()
menu.Show
End Sub
Form6
64
Berikut ini listing programnya
Private Sub Command1_Click()
PM = Val(P1) * Val(r) ^ 1.4 * (1.4 * (Val(RO) - 1) - Val(r) ^ 1 - 1.4 *
(Val(RO) ^ 1.4 - 1))
End Sub
65
Private Sub Command7_Click()
RO = Val(V3) / Val(V2)
End Sub
66
Aplikasi berjalan dan di input dengan data
67
68
Pembuatan program & selesai
69
BAB IV
PENUTUP
4.1 Kesimpulan
70
4.2 Saran
71