0% found this document useful (0 votes)
62 views2 pages

Employee Search Program Code

This document describes a program that allows users to search and view employee data from a database table. The program loads employee ID numbers into a dropdown list. When an ID is selected, text boxes are populated with the corresponding employee name, department, job title, and status from the database. Users can also click a button to display all data for the selected employee in a read-only datagrid. The program connects to the database, builds SQL queries to retrieve employee data by ID, and displays the results in the user interface.

Uploaded by

Rona Veriansyah
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
62 views2 pages

Employee Search Program Code

This document describes a program that allows users to search and view employee data from a database table. The program loads employee ID numbers into a dropdown list. When an ID is selected, text boxes are populated with the corresponding employee name, department, job title, and status from the database. Users can also click a button to display all data for the selected employee in a read-only datagrid. The program connects to the database, builds SQL queries to retrieve employee data by ID, and displays the results in the user interface.

Uploaded by

Rona Veriansyah
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

Listing program search

Listing program
Imports [Link]
Public Class FormSearch

Private Sub FormSearch_Load(ByVal sender As [Link], ByVal e As


[Link]) Handles [Link]
koneksi()

tampilkannik()
End Sub
Sub tampilkannik()

cmd = New OleDbCommand("Select NIK from tabelkaryawan ", con)


rd = [Link]
Do While [Link]
[Link]([Link]("NIK"))

Loop
End Sub

Private Sub cbonik_SelectedIndexChanged(ByVal sender As Object, ByVal e As


[Link]) Handles [Link]
cmd = New OleDbCommand("Select NIK,Nama,Departement,Jabatan,Status
from tabelkaryawan where NIK='" & [Link] & "'", con)
rd = [Link]
[Link]()
If [Link] = True Then
[Link] = [Link]("Nama")
[Link] = [Link]("Jabatan")
[Link] = [Link]("Status")
[Link] = [Link]("Departement")

1
End If
End Sub

Private Sub Button1_Click(ByVal sender As [Link], ByVal e As


[Link]) Handles [Link]
koneksi()
cmd = New OleDbCommand("Select NIK,Nama,Departement,Jabatan,Status
from tabelkaryawan where NIK='" & [Link] & "'", con)
rd = [Link]

Do While [Link]

ds = New DataSet

[Link] = [Link]("tabelkaryawan")
[Link] = True

Loop
End Sub
End Class

You might also like