DATA BASE UTS

Private Sub cmdbaru_Click()
Data1.Recordset.AddNew
txtnama.SetFocus
End Sub

Private Sub cmddelete_Click()
Data1.Recordset.Delete
End Sub

Private Sub cmdedit_Click()
Data1.Recordset.Edit
End Sub

Private Sub CMDPROSES_Click()
Dim s As String
s = Left(txtnik.Text, 3)
If s = “KEU” Then
txtbagian.Text = “ACCOUNTING”

ElseIf s = “ADM” Then
txtbagian.Text = “ADMINISTRATION”

ElseIf s = “SDM” Then
txtbagian.Text = “GENERAL AFFAIR”

ElseIf s = “EDP” Then
txtbagian.Text = “IT UNIT”

ElseIf s = “SPM” Then
txtbagian.Text = “SECURITY”
End If

s = Mid(txtnik.Text, 9, 1)
If s = “A” Then
txtgolongan.Text = “A”
txtjabatan.Text = “MANAGER”
txtgapok.Text = “3000000”
txttunjangan.Text = “875000”

ElseIf s = “B” Then
txtgolongan.Text = “B”
txtjabatan.Text = “KA SEKSI”
txtgapok.Text = “2500000”
txttunjangan.Text = “525000”

ElseIf s = “C” Then
txtgolongan.Text = “C”
txtjabatan.Text = “STAFF”
txtgapok.Text = “2000000”
txttunjangan.Text = “325000”
End If

txttotalgaji.Text = Val(txttunjangan.Text) + Val(txtgapok.Text)

s = Mid(txtnik.Text, 5, 4)
txttahun.Text = s

s = Right(txtnik.Text, 1)
If s = “S” Then
txtkodestatus.Text = “S”
txtstatus.Text = “SINGLE”

ElseIf s = “M” Then
txtkodestatus.Text = “M”
txtstatus.Text = “MENIKAH”

ElseIf s = “D” Then
txtkodestatus.Text = “D”
txtstatus.Text = “DUDA”

ElseIf s = “J” Then
txtkodestatus.Text = “J”
txtstatus.Text = “JANDA”
End If

End Sub

Private Sub cmdsave_Click()
Data1.Recordset.Update
End Sub

Private Sub Command4_Click()
End
End Sub

Private Sub txtnama_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txtnik.SetFocus
End If
End Sub

About irfanstmik

KEJUJURAN ADALAH MODAL UTAMA UNTUK MEMPEROLEH KEPERCAYAAN

Posted on February 15, 2012, in Uncategorized. Bookmark the permalink. Leave a comment.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: