tugas 3

IMG_20160103_215233

Private Sub kosong()

Txtnama.SetFocus

Txtnama.Text = “”

Txtnpm.Text = “”

Txtjur.Text = “”

Txtpro.Text = “”

Txtthn.Text = “”

Txtno.Text = “”

End Sub

Private Sub Cmdbatal_Click()

kosong

End Sub

 

Private Sub Cmdkeluar_Click()

Unload Me

End Sub

 

Private Sub Cmdlagi_Click()

kosong

End Sub

 

Private Sub Cmdproses_Click()

Dim J As String

J = Mid(Txtnpm.Text, 3, 1)

If J = “1” Then

Txtjur.Text = “Sistem Informasi”

Txtpro.Text = “Strata Satu”

ElseIf J = “2” Then

Txtjur.Text = “Teknik Informatika”

Txtpro.Text = “Diploma Empat”

ElseIf J = “3” Then

Txtjur.Text = “Management Informatika”

Txtpro.Text = “Diploma Tiga”

ElseIf J = “4” Then

Txtjur.Text = “Komputer Akuntansi”

Txtpro.Text = “Diploma Dua”

End If

Txtthn.Text = “20” & Left(Txtnpm.Text, 2)

Txtno.Text = Right(Txtnpm.Text, 3)

End Sub

 

Private Sub Form_Activate()

Txtnama.SetFocus

Txtnama.Text = “”

Txtnpm.Text = “”

Txtjur.Text = “”

Txtpro.Text = “”

Txtthn.Text = “”

Txtno.Text = “”

End Sub

 

Private Sub Txtnama_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

Txtnpm.SetFocus

End If

End Sub

Advertisements
Standard

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 )

Google+ photo

You are commenting using your Google+ 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 )

Connecting to %s