Public Class DataAbsensi
Dim isitext(8) As String
Dim listampil As ListViewItem
Private Sub DataAbsensi_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Activated
Call tampil()
End Sub
Sub bersih()
TextBox1.Text = ""
TextBox2.Text = ""
TextBox3.Text = ""
TextBox4.Text = ""
TextBox5.Text = ""
TextBox6.Text = ""
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
End Sub
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
If Button2.Text = "Tambah" Then
Button2.Text = "Simpan"
Button1.Enabled = False
Button3.Enabled = False
Button4.Text = "Batal"
Button5.Enabled = False
Button6.Text = "Keluar"
TextBox2.Focus()
Else
isitext(0) = ComboBox1.Text
isitext(1) = TextBox1.Text
isitext(2) = DateTimePicker1.Text
isitext(3) = TextBox2.Text
isitext(4) = TextBox3.Text
isitext(5) = TextBox4.Text
isitext(6) = TextBox5.Text
isitext(7) = TextBox6.Text
Button2.Text = "Tambah"
Button1.Enabled = True
Button3.Enabled = True
Button5.Enabled = True
TextBox2.Focus()
listampil = New ListViewItem(isitext)
ListView1.Items.Add(listampil)
Call bersih()
TextBox1.Focus()
End If
End Sub
Sub normal()
Button1.Text = "Cari"
Button1.Enabled = True
Button2.Text = "Tambah"
Button2.Enabled = True
Button3.Text = "Edit"
Button3.Enabled = True
Button4.Text = "Batal"
Button4.Enabled = True
Button5.Text = "Hapus"
Button5.Enabled = True
Button6.Text = "Keluar"
Button6.Enabled = True
End Sub
Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
End Sub
Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click
Button1.Enabled = True
Button3.Enabled = True
Button5.Enabled = True
Button2.Text = "Tambah"
bersih()
End Sub
Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click
ListView1.FocusedItem.Remove()
End Sub
Private Sub Button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button6.Click
If Button6.Text = "Keluar" Then
Me.Close()
Else
Call bersih()
Call normal()
End If
End Sub
Sub tampil()
ListView1.View = View.Details
ListView1.Columns.Add("NO ABS", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("NIK", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("TANGGAL", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Jum Msk", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("ALPA", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("SAKIT", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("IJIN", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("JUM ABS", 100, HorizontalAlignment.Center)
End Sub
Private Sub ListView1_ItemSelectionChanged(ByVal sender As Object, ByVal e As System.Windows.Forms.ListViewItemSelectionChangedEventArgs) Handles ListView1.ItemSelectionChanged
TextBox1.Text = e.Item.Text
End Sub
End Class
Public Class datapotongan
Dim isitext(5) As String
Dim listampil As ListViewItem
Private Sub datapotongan_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Activated
Call normal()
Call tampil()
End Sub
Private Sub datapotongan_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
End Sub
Sub bersih()
ComboBox1.Text = " "
TextBox1.Text = " "
TextBox2.Text = " "
TextBox3.Text = " "
End Sub
Sub normal()
Button1.Text = "Cari"
Button1.Enabled = True
Button2.Text = "Tambah"
Button2.Enabled = True
Button3.Text = "Edit"
Button3.Enabled = True
Button4.Text = "Batal"
Button4.Enabled = True
Button5.Text = "Hapus"
Button5.Enabled = True
Button6.Text = "Keluar"
Button6.Enabled = True
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
End Sub
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
If Button2.Text = "Tambah" Then
Button2.Text = "Simpan"
Button1.Enabled = False
Button3.Enabled = False
Button4.Text = "Batal"
Button5.Enabled = False
Button6.Text = "Keluar"
TextBox2.Focus()
Else
isitext(0) = DateTimePicker1.Text
isitext(1) = ComboBox1.Text
isitext(2) = TextBox1.Text
isitext(3) = TextBox2.Text
isitext(4) = TextBox3.Text
Button2.Text = "Tambah"
Button1.Enabled = True
Button3.Enabled = True
Button5.Enabled = True
TextBox2.Focus()
listampil = New ListViewItem(isitext)
ListView1.Items.Add(listampil)
Call bersih()
TextBox1.Focus()
End If
End Sub
Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
End Sub
Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click
Button1.Enabled = True
Button3.Enabled = True
Button5.Enabled = True
Button2.Text = "Tambah"
bersih()
End Sub
Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click
ListView1.FocusedItem.Remove()
End Sub
Private Sub Button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button6.Click
If Button6.Text = "Keluar" Then
Me.Close()
Else
Call bersih()
Call normal()
End If
End Sub
Sub tampil()
ListView1.View = View.Details
ListView1.Columns.Add("Tanggal", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("NIK", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Nama", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Pot Kop", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Pot Kes", 100, HorizontalAlignment.Center)
End Sub
Private Sub ListView1_ItemSelectionChanged(ByVal sender As Object, ByVal e As System.Windows.Forms.ListViewItemSelectionChangedEventArgs) Handles ListView1.ItemSelectionChanged
TextBox1.Text = e.Item.Text
End Sub
Public Class DataGaji
Dim isitext(16) As String
Dim listampil As ListViewItem
Private Sub DataGaji_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Activated
Call tampil()
End Sub
Sub bersih()
ComboBox1.Text = ""
TextBox1.Text = ""
TextBox2.Text = ""
TextBox3.Text = ""
TextBox4.Text = ""
TextBox5.Text = ""
TextBox6.Text = ""
TextBox7.Text = ""
TextBox8.Text = ""
TextBox9.Text = ""
TextBox10.Text = ""
TextBox11.Text = ""
TextBox12.Text = ""
TextBox13.Text = ""
TextBox14.Text = ""
TextBox15.Text = ""
End Sub
Sub normal()
Button1.Text = "Cari"
Button1.Enabled = True
Button2.Text = "Tambah"
Button2.Enabled = True
Button3.Text = "Batal"
Button3.Enabled = True
Button4.Text = "Hapus"
Button4.Enabled = True
Button5.Text = "Keluar"
Button5.Enabled = True
Button6.Text = "Cetak"
Button6.Enabled = True
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
End Sub
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
If Button2.Text = "Tambah" Then
Button2.Text = "Simpan"
Button1.Enabled = False
Button3.Text = "Batal"
Button4.Enabled = False
Button5.Text = "Keluar"
Button6.Enabled = False
TextBox1.Focus()
Else
isitext(0) = ComboBox1.Text
isitext(1) = TextBox1.Text
isitext(2) = TextBox2.Text
isitext(3) = TextBox3.Text
isitext(4) = TextBox4.Text
isitext(5) = TextBox5.Text
isitext(6) = TextBox6.Text
isitext(7) = TextBox7.Text
isitext(8) = TextBox8.Text
isitext(9) = TextBox9.Text
isitext(10) = TextBox10.Text
isitext(11) = TextBox11.Text
isitext(12) = TextBox12.Text
isitext(13) = TextBox13.Text
isitext(14) = TextBox14.Text
isitext(15) = TextBox15.Text
Button2.Text = "Tambah"
Button1.Enabled = True
Button3.Enabled = True
Button5.Enabled = True
TextBox2.Focus()
listampil = New ListViewItem(isitext)
ListView1.Items.Add(listampil)
Call bersih()
Call normal()
TextBox1.Focus()
End If
End Sub
Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
Button1.Enabled = True
Button4.Enabled = True
Button6.Enabled = True
Button2.Text = "Tambah"
Call bersih()
End Sub
Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click
ListView1.FocusedItem.Remove()
End Sub
Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click
If Button5.Text = "Keluar" Then
Me.Close()
Else
Call bersih()
Call normal()
End If
End Sub
Private Sub Button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button6.Click
End Sub
Sub tampil()
ListView1.View = View.Details
ListView1.Columns.Add("NIK", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Nama", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Jabatan", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Masa Kerja", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Gaji Pokok", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Tunj Jabatan", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Tunj Keluarga", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Tunj Kesehatan", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Tunj Transport", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Total Tunj", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Pot Transport", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Pot Kesehatan", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Pot Koperasi", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Total Pot", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Gaji Kotor", 100, HorizontalAlignment.Center)
ListView1.Columns.Add("Gaji Bersih", 100, HorizontalAlignment.Center)
End Sub
Private Sub ListView1_ItemSelectionChanged(ByVal sender As Object, ByVal e As System.Windows.Forms.ListViewItemSelectionChangedEventArgs) Handles ListView1.ItemSelectionChanged
TextBox1.Text = e.Item.Text
End Sub
End Class
Laporan gaji belum dibuat source code nya.
(selamat mencoba)