Tugas 4

AHMAD41

Private Sub Command1_Click()

Dim K, J, P, H, N As String

K = Mid(CMB1.Text, 3, 3)

If K = “SIM” Then

J = “SISTEM INFORMASI MANAJEMAN”

P = “YATI NUR OKTAFIA”

H = “75900”

ElseIf K = “EDP” Then

J = “ELEKTRONIK DATA PROCESSING”

P = “IMAM TARMIJI”

H = “62000”

ElseIf K = “MNJ” Then

J = “MANAJEMEN”

P = “VALENTINA MARIANA ADIWIATI”

H = “42000”

ElseIf K = “CDR” Then

J = ” COREL DRAW”

P = “RIYAN SUHANDI”

H = “53000”

ElseIf K = “RPL” Then

J = “REKAYASA PERANGKAT LUNAK”

P = “SINTA UMPU SINGA”

H = “83000”

End If

Text1.Text = J

Text2.Text = P

Text5.Text = H

 

K = Left(CMB1.Text, 1)

If K = “A” Then

N = “ANDI OFFSET YOGYAKARTA”

ElseIf K = “I” Then

N = “INDAH SURABAYA”

ElseIf K = “S” Then

N = “SALEMBA EMPAT”

ElseIf K = “E” Then

N = “ELEK MEDIA KOMPUTINDO”

ElseIf K = “M” Then

N = “MAXICOM”

End If

 

Text4.Text = N

Text3.Text = “20” & Right(CMB1.Text, 2)

End Sub

 

Private Sub Command2_Click()

Text1.SetFocus

Text1 = “”

Text2 = “”

Text3 = “”

Text4 = “”

Text5 = “”

End Sub

 

Private Sub Command3_Click()

Text1.SetFocus

Text1 = “”

Text2 = “”

Text3 = “”

Text4 = “”

Text5 = “”

End Sub

 

Private Sub Command4_Click()

Unload Me

End Sub

 

Private Sub Form_Load()

CMB1.AddItem “A-SIM-01”

CMB1.AddItem “I-EDP-02”

CMB1.AddItem “S-MNJ-03”

CMB1.AddItem “E-CDR-04”

CMB1.AddItem “M-RPL-05”

End Sub

AHMAD42

Private Sub Combo1_Click()

Dim A, B, C, D As String

Select Case Combo1.Text

Case “I”

A = 2000000

B = 500000

Case “II”

A = 2250000

B = 500000

Case “III”

A = 2500000

B = 500000

End Select

D = A + B

C = D * 0.1

Text3.Text = A

Text4.Text = B

Text5.Text = C

Text6.Text = D – C

End Sub

 

Private Sub Command1_Click()

Text1.SetFocus

Text1 = “”

Text2 = “”

Text3 = “”

Text4 = “”

Text5 = “”

Text6 = “”

End Sub

 

Private Sub Command2_Click()

Text1.SetFocus

Text1 = “”

Text2 = “”

Text3 = “”

Text4 = “”

Text5 = “”

Text6 = “”

End Sub

 

Private Sub Command3_Click()

Unload Me

End Sub

 

Private Sub Form_Load()

Combo1.AddItem “I”

Combo1.AddItem “II”

Combo1.AddItem “III”

End Sub

 

 

 

Private Sub Text1_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

Text2.SetFocus

End If

End Sub

 

Private Sub Text2_Change()

 

End Sub

ahmad43

Private Sub Combo1_Click()

Dim N, J As String

Select Case Combo1.Text

Case “12100491”

N = “Bhramita Vidya Nirmala Husada”

J = “Manajemen Informatika”

Case “12100492”

N = “Hasim Saputra”

J = “Sistem Informasi”

Case “12100493”

N = “Mega Andar Putri”

J = “Manajemen Informatika”

Case “12100494”

N = “Wulan Novitaloka”

J = “Manajemen Informatika”

Case “12100495”

N = “Ngindana Zulfa”

J = “Manajemen Informatika”

Case “12100496”

N = “Ahmad Nur Fuadi”

J = “Manajemen Informatika”

Case “12100497”

N = “Joni Purnama”

J = “Sistem Informasi”

Case “12100498”

N = “Arif Bestari”

J = “Sistem Informasi”

End Select

Text1.Text = N

Text2.Text = J

Text3.SetFocus

End Sub

 

Private Sub Command1_Click()

Text7.Text = Val(Text3.Text) + Val(Text4.Text) + Val(Text5.Text) + Val(Text6.Text)

Text7.Text = Text7.Text / 4

If Text7.Text >= 90 Then

Text8.Text = “A”

ElseIf Text7.Text >= 80 Then

Text8.Text = “B”

ElseIf Text7.Text >= 70 Then

Text8.Text = “C”

ElseIf Text7.Text >= 60 Then

Text8.Text = “D”

ElseIf Text7.Text <= 50 Then

Text8.Text = “E”

 

End If

End Sub

 

Private Sub Command2_Click()

Text3.SetFocus

Text3 = “”

Text4 = “”

Text5 = “”

Text6 = “”

Text7 = “”

Text8 = “”

End Sub

 

Private Sub Command3_Click()

U

End Sub

 

Private Sub Form_Load()

Combo1.AddItem “12100491”

Combo1.AddItem “12100492”

Combo1.AddItem “12100493”

Combo1.AddItem “12100494”

Combo1.AddItem “12100495”

Combo1.AddItem “12100496”

Combo1.AddItem “12100497”

Combo1.AddItem “12100498”

End Sub

 

 

Private Sub Text3_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

Text4.SetFocus

End If

End Sub

 

 

 

Private Sub Text4_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

Text5.SetFocus

End If

End Sub

 

 

 

Private Sub Text5_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

Text6.SetFocus

End If

End Sub

 

Advertisements

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