Rabu, 23 Februari 2011
23-02-2011
Hari ini saya ingin bisa menmpilkan data yang sudah ada di database dan bisa Editnya
Selasa, 22 Februari 2011
Hari ke 31 PI
PENAMBAHAN CODING AUTO NUMBER + INSERT INTO
Private Sub Command_Click(Index As Integer)
Select Case Index
Case 0 ' TAMBAH
kosong True
Text(0) = AutoNum("S", 5, "siswa", "kde_siswa")
Text(0).Enabled = True
st = True
Text(0).SetFocus
Call aktif
enbTombol False, True, False, False, True, False, True
Command(5).Visible = False
Case 1 'SIMPAN
If cek = True Then
MsgBox "Isikan Data Dengan Benar!", vbInformation, "Kosong"
Exit Sub
End If
ya = MsgBox("Apakah Anda yakin data ini akan Anda simpan?", vbQuestion + vbYesNo, "Simpan")
If ya = vbYes Then
Set rs = ConnAPP.Execute("SELECT * FROM Siswa WHERE Kde_Siswa = '" & Text(0).Text & "'")
If Not rs.EOF Then
rs.Close
Set rs = ConnAPP.Execute("UPDATE Siswa set NIS='" & Text(1).Text & "',Nama='" & Text(2).Text & "',Tmpt='" & Text(3).Text & "',TL='" & DTPicker1 & "',Alamat='" & Text(4).Text & "', Masuk='" & Text(2).Text & "',Keluar='" & Text(2).Text & "',Sex='" & Combo(0) & "',Agama='" & Combo(1) & "' WHERE Kde_Siswa = '" & Text(0).Text & "'")
MsgBox "Berhasil Disimpan", vbInformation + vbOKOnly, "Simpan"
Else
rs.Close
Set rs = ConnAPP.Execute("insert into Siswa(Kde_Siswa,NIS,Nama,Sex,Tmpt, TL, Agama,Alamat, Masuk, Keluar)values('" & Text(0) & "','" & Text(1) & "','" & Text(2) & "','" & Combo(0) & "','" & Text(3) & "','" & DTPicker1 & "','" & Combo(1) & "','" & Text(4) & "','" & Text(5) & "','" & Text(6) & "')")
MsgBox "Berhasil Disimpan", vbInformation + vbOKOnly, "Simpan"
End If
Call tampil
enbTombol True, False, False, False, True, False, True
Command(6).Visible = True
End If
Case 4 'KELUAR
Unload Me
Case 5 'BATAL
Unload Me
End Select
End Sub
Private Sub Command_Click(Index As Integer)
Select Case Index
Case 0 ' TAMBAH
kosong True
Text(0) = AutoNum("S", 5, "siswa", "kde_siswa")
Text(0).Enabled = True
st = True
Text(0).SetFocus
Call aktif
enbTombol False, True, False, False, True, False, True
Command(5).Visible = False
Case 1 'SIMPAN
If cek = True Then
MsgBox "Isikan Data Dengan Benar!", vbInformation, "Kosong"
Exit Sub
End If
ya = MsgBox("Apakah Anda yakin data ini akan Anda simpan?", vbQuestion + vbYesNo, "Simpan")
If ya = vbYes Then
Set rs = ConnAPP.Execute("SELECT * FROM Siswa WHERE Kde_Siswa = '" & Text(0).Text & "'")
If Not rs.EOF Then
rs.Close
Set rs = ConnAPP.Execute("UPDATE Siswa set NIS='" & Text(1).Text & "',Nama='" & Text(2).Text & "',Tmpt='" & Text(3).Text & "',TL='" & DTPicker1 & "',Alamat='" & Text(4).Text & "', Masuk='" & Text(2).Text & "',Keluar='" & Text(2).Text & "',Sex='" & Combo(0) & "',Agama='" & Combo(1) & "' WHERE Kde_Siswa = '" & Text(0).Text & "'")
MsgBox "Berhasil Disimpan", vbInformation + vbOKOnly, "Simpan"
Else
rs.Close
Set rs = ConnAPP.Execute("insert into Siswa(Kde_Siswa,NIS,Nama,Sex,Tmpt, TL, Agama,Alamat, Masuk, Keluar)values('" & Text(0) & "','" & Text(1) & "','" & Text(2) & "','" & Combo(0) & "','" & Text(3) & "','" & DTPicker1 & "','" & Combo(1) & "','" & Text(4) & "','" & Text(5) & "','" & Text(6) & "')")
MsgBox "Berhasil Disimpan", vbInformation + vbOKOnly, "Simpan"
End If
Call tampil
enbTombol True, False, False, False, True, False, True
Command(6).Visible = True
End If
Case 4 'KELUAR
Unload Me
Case 5 'BATAL
Unload Me
End Select
End Sub
22-02-2011
Hari ini saya akan mencoba menambahkan Sricpt untuk menmbah data siswa di database
Senin, 21 Februari 2011
Hari ke 30 PI
Hari ini saya dapat mengkonekssikan MYSQL SERVER dan VB 6.0 meskipun banyak kendala. Selain itu saya juga sudah menata sript untuk bermain tombol dalam Data Siswa ..
21-02-2011
Hari ini saya ingin untuk bisa menambahkan unutk bisa tambah data dan bisa tampil tersimpan database
Rabu, 16 Februari 2011
Hari ke 28 PI
Hari ini saya edit foto dengan teknik-teknik baru . . . .
1. Efect Pecah
2. Efect Infra Red
3. Martix
4. Efect Brewok
1. Efect Pecah
2. Efect Infra Red
3. Martix
4. Efect Brewok
Senin, 14 Februari 2011
14-02-2011
Hari ini saya menginginkan untuk menyelasaikan semua tabel yang bermasalah
Langganan:
Postingan (Atom)




