Desain Form
Source Code
Private Sub cmdkeluar_Click()
End
End Sub
Private Sub cmdulang_Click()
Txt1.SetFocus
Txt1.Text = ""
Txt2.Text = ""
Opsiganjil.Value = False
Opsigenap.Value = False
cboperulangan = "Pilih Jenis Perulangan"
lbljumlah.Caption = ""
lblrata.Caption = ""
List1.Clear
End Sub
Private Sub Cboperulangan_click()
Dim awal, akhir As String
Dim jum, rata As Double
awal = Txt1.Text
akhir = Txt2.Text
If awal = "" And akhir = "" Then
MsgBox "NILAI AWAL DAN NILAI AKHIR BELUM ANDA INPUTKAN !!!"
ElseIf awal = "" Or akhir = "" Then
MsgBox "NILAI AWAL ATAU NILAI AKHIR BELUM ANDA INPUTKAN !!!"
ElseIf Opsiganjil.Value = False And Opsigenap.Value = False Then
MsgBox "PILIHAN BILANGAN BELUM DIPILIH !!!"
ElseIf cboperulangan = "For" And Opsiganjil.Value = True Then
List1.Clear
If awal <= akhir Then
For i = awal To akhir
If i Mod 2 = 1 Then
List1.AddItem i
jum = jum + i
awal = awal + 2
n = n + 1
End If
Next i
rata = jum / n
lbljumlah.Caption = jum
lblrata.Caption = rata
ElseIf awal > akhir Then
MsgBox "nilai awal harus kurang dari nilai akhir"
End If
ElseIf cboperulangan = "Do While" And Opsiganjil.Value = True Then
List1.Clear
If awal <= akhir Then
Do
If awal Mod 2 = 1 Then
List1.AddItem (awal)
n = n + 1
jum = jum + awal
End If
awal = awal + 1
Loop While awal <= akhir
rata = jum / n
lbljumlah.Caption = jum
lblrata.Caption = rata
ElseIf awal > akhir Then
MsgBox "nilai awal harus kurang dari nilai akhir"
End If
ElseIf cboperulangan = "Do Until" And Opsiganjil.Value = True Then
List1.Clear
If awal <= akhir Then
Do
If awal Mod 2 = 1 Then
List1.AddItem (awal)
n = n + 1
jum = jum + awal
End If
awal = awal + 1
Loop Until awal > akhir
rata = jum / n
lbljumlah.Caption = jum
lblrata.Caption = rata
ElseIf awal > akhir Then
MsgBox "nilai awal harus kurang dari nilai akhir"
End If
ElseIf cboperulangan = "For" And Opsigenap.Value = True Then
List1.Clear
If awal <= akhir Then
For i = awal To akhir
If i Mod 2 = 0 Then
List1.AddItem i
jum = jum + i
m = m + i
n = n + 1
End If
Next i
rata = jum / n
lbljumlah.Caption = jum
lblrata.Caption = rata
ElseIf awal > akhir Then
MsgBox "nilai awal harus kurang dari nilai akhir"
End If
ElseIf cboperulangan = "Do While" And Opsigenap.Value = True Then
List1.Clear
If awal <= akhir Then
Do
If awal Mod 2 = 0 Then
List1.AddItem (awal)
n = n + 1
jum = jum + awal
End If
awal = awal + 1
Loop While awal <= akhir
rata = jum / n
lbljumlah.Caption = jum
lblrata.Caption = rata
ElseIf awal > akhir Then
MsgBox "nilai awal harus kurang dari nilai akhir"
End If
ElseIf cboperulangan = "Do Until" And Opsigenap.Value = True Then
List1.Clear
If awal <= akhir Then
Do
If awal Mod 2 = 0 Then
List1.AddItem (awal)
n = n + 1
jum = jum + awal
End If
awal = awal + 1
Loop Until awal > akhir
rata = jum / n
lbljumlah.Caption = jum
lblrata.Caption = rata
ElseIf awal > akhir Then
MsgBox "nilai awal harus kurang dari nilai akhir"
End If
End If
End Sub
Private Sub Form_Load()
cboperulangan.AddItem "For"
cboperulangan.AddItem "Do While"
cboperulangan.AddItem "Do Until"
End Sub
SILAHKAN DOWNLOAD PROGRAMNYA DISINI
Senin, 14 Oktober 2013
Posts by : Admin
Posts by : Admin
Program Pencarian Simpangan Baku dengan Microsoft Visual Basic 6.0
Desain form
Source Code
Private Sub Cmdhitung_Click()
Dim i, n, jum, jumkuadrat, simpanganbaku, rata As Double
For i = 0 To List1.ListCount - 1
jum = jum + Val(List1.List(i))
jumkuadrat = jumkuadrat + (List1.List(i)) ^ 2
n = n + 1
Next i
rata = jum / n
simpanganbaku = Sqr(((n * jumkuadrat) - (jum ^ 2)) / (n * (n - 1)))
lbljumlah.Caption = jum
lblrata.Caption = rata
lblsb.Caption = simpanganbaku
End Sub
Private Sub cmdkeluar_Click()
End
End Sub
Private Sub cmdulang_Click()
List1.SetFocus
List1.Clear
lbljumlah.Caption = ""
lblrata.Caption = ""
lblsb.Caption = ""
End Sub
Private Sub Txt1_keypress(keyascii As Integer)
Dim a As Integer
a = Val(Txt1.Text)
If keyascii = 13 Then
List1.AddItem a
Txt1.Text = ""
End If
End Sub
Silahkan download programnya disini
Posts by : Admin
Posts by : Admin
Posts by : Admin
Melukis Sudut 36
OBuat lingkaran dan sudut 90°.
OBagi r lingkaran menjadi dua pada
titik C.
ODari titik C jangkaukan sepanjang R
sehingga memotong AB di D.
OJangkaukan OD pada keliling
lingkaran dimulai dari E.
ODari titik O tarik garis ke F
sehingga terbentuk sudut 36°.
Posts by : Admin
BUKU AJAR PENGANTAR STRUKTUR ALJABAR 1 (PSA 1) UNIVERSITAS NEGERI SEMARANG
BUKU AJAR
Mata Kuliah : Pengantar Struktur Aljabar 1
No. Kode Mata Kuliah : MAT205
Semester : 3
Nama Dosen : Isnarto, S.Pd, M.Si
NIP : 132092853
Jurusan/Program Studi : Matematika/ S-1 Matematika,
S-1 Pend. Matematika
FAKULTAS MATEMATIKA DAN ILMU PENGETAHUAN ALAM
UNIVERSITAS NEGERI SEMARANG
2008
Langganan:
Postingan (Atom)
You can replace this text by going to "Layout" and then "Page Elements" section. Edit " About "