Braincode
11th November 2011, 02:14 PM
Quote:
Originally Posted by bstarconspiracy
http://static.kaskus.us/images/buttons/viewpost.gif (http://www.ceriwis.org/showthread.php?p=222320583#post222320583)
pagi all maaf neh ane lagi kesusahaan gan :kabur:
lagi nyelesain tugas akhir :hammer:
mohon bantuannya gan :handshake:
ane punya tampilan form yang gini
Spoiler for input data barang:
http://u.kaskus.us/4/hdki5sds.jpeg
nah ane mentok pas di tombol carinya gan
ane pake adodc ke access gan :ganteng:
Code:
Private Sub Command5_Click()
Dim a, b As Integer
Adodc1.Recordset.MoveFirst
a = Adodc1.Recordset.RecordCount
b = 0
Do While Not Adodc1.Recordset.EOF
b = b + 1
If Combo1.Text = "Kode Barang" Then
MsgBox ("data di temukan")
If Adodc1.Recordset!Kode_Barang = Text6.Text Then
Text1.Text = Adodc1.Recordset!Kode_Barang
Text2.Text = Adodc1.Recordset!Nama_Barang
Text3.Text = Adodc1.Recordset!Jenis_Barang
Text4.Text = Adodc1.Recordset!Satuan
Text5.Text = Adodc1.Recordset!Harga
Exit Do
ElseIf a = b Then
MsgBox ("data tidak ditemukan")
Exit Do
End If
ElseIf Combo1.Text = "Nama Barang" Then
If UCase(Adodc1.Recordset!Nama_Barang) = UCase(Text6.Text) Then
Text1.Text = Adodc1.Recordset!Kode_Barang
Text2.Text = Adodc1.Recordset!Nama_Barang
Text3.Text = Adodc1.Recordset!Jenis_Barang
Text4.Text = Adodc1.Recordset!Satuan
Text5.Text = Adodc1.Recordset!Harga
Exit Do
ElseIf a = b Then
MsgBox ("data tidak ditemukan")
Exit Do
End If
ElseIf Combo1.Text = "" Or Text6.Text = "" Then
MsgBox ("anda belum memasukan pilihan pencarian")
Exit Do
End If
Adodc1.Recordset.MoveNext
Loop
End Sub
Private Sub Command6_Click()
End
End Sub
ohh yahh kalo da yang kurang n salah mohon koreksinya gan makasih :shakehand:
</div>
Originally Posted by bstarconspiracy
http://static.kaskus.us/images/buttons/viewpost.gif (http://www.ceriwis.org/showthread.php?p=222320583#post222320583)
pagi all maaf neh ane lagi kesusahaan gan :kabur:
lagi nyelesain tugas akhir :hammer:
mohon bantuannya gan :handshake:
ane punya tampilan form yang gini
Spoiler for input data barang:
http://u.kaskus.us/4/hdki5sds.jpeg
nah ane mentok pas di tombol carinya gan
ane pake adodc ke access gan :ganteng:
Code:
Private Sub Command5_Click()
Dim a, b As Integer
Adodc1.Recordset.MoveFirst
a = Adodc1.Recordset.RecordCount
b = 0
Do While Not Adodc1.Recordset.EOF
b = b + 1
If Combo1.Text = "Kode Barang" Then
MsgBox ("data di temukan")
If Adodc1.Recordset!Kode_Barang = Text6.Text Then
Text1.Text = Adodc1.Recordset!Kode_Barang
Text2.Text = Adodc1.Recordset!Nama_Barang
Text3.Text = Adodc1.Recordset!Jenis_Barang
Text4.Text = Adodc1.Recordset!Satuan
Text5.Text = Adodc1.Recordset!Harga
Exit Do
ElseIf a = b Then
MsgBox ("data tidak ditemukan")
Exit Do
End If
ElseIf Combo1.Text = "Nama Barang" Then
If UCase(Adodc1.Recordset!Nama_Barang) = UCase(Text6.Text) Then
Text1.Text = Adodc1.Recordset!Kode_Barang
Text2.Text = Adodc1.Recordset!Nama_Barang
Text3.Text = Adodc1.Recordset!Jenis_Barang
Text4.Text = Adodc1.Recordset!Satuan
Text5.Text = Adodc1.Recordset!Harga
Exit Do
ElseIf a = b Then
MsgBox ("data tidak ditemukan")
Exit Do
End If
ElseIf Combo1.Text = "" Or Text6.Text = "" Then
MsgBox ("anda belum memasukan pilihan pencarian")
Exit Do
End If
Adodc1.Recordset.MoveNext
Loop
End Sub
Private Sub Command6_Click()
End
End Sub
ohh yahh kalo da yang kurang n salah mohon koreksinya gan makasih :shakehand:
</div>