belajar usaha, materi smk, game

contoh aplikasi praktik vb


Private Sub Command1_Click()

txtnim.Text = ""
txtnama.Text = ""
cmbjurusan.Text = ""
txtipk.Text = 0
txtnim.Enabled = True
txtnama.Enabled = True
cmbjurusan.Enabled = True
txtipk.Enabled = True
txtnim.SetFocus
End Sub

Private Sub Command2_Click()

Data1.Recordset.AddNew
Data1.Recordset!nim = txtnim.Text
Data1.Recordset!nama = txtnama.Text
Data1.Recordset!jurusan = cmbjurusan.Text
Data1.Recordset!ipk = txtipk.Text
Data1.Recordset.Update
Data1.Refresh
End Sub

Private Sub Command3_Click()

Dim x As Integer

x = MsgBox("Apakah anda yakin ingin menghapus data obat?", vbQuestion + vbYesNo, "Hapus?")

If x = vbYes Then

Data1.Recordset.Delete

Data1.Recordset.MoveNext

If Data1.Recordset.EOF = True Then

Data1.Recordset.MovePrevious
End If
End If
End Sub

Private Sub Command4_Click()

Data1.Recordset.Edit
Data1.Recordset.Update
Data1.Refresh
End Sub

Private Sub Command5_Click()

Unload Me
End Sub

Private Sub Form_Activate()
txtnim.Enabled = False
txtnama.Enabled = False
cmbjurusan.Enabled = False
txtipk.Enabled = False
Command1.Enabled = True

End Sub

Anda baru saja membaca artikel yang berkategori visual basic dengan judul contoh aplikasi praktik vb. Anda bisa bookmark halaman ini dengan URL http://saapii.blogspot.com/2013/06/contoh-aplikasi-praktik-vb.html. Terima kasih!
Ditulis oleh: syaiful ridlo - Friday, 14 June 2013

Belum ada komentar untuk "contoh aplikasi praktik vb"

Post a Comment