TUGAS VB 4




Private Sub Combo1_Click()
Select Case Combo1.Text
Case “SERABAYA-JAKARTA”
Text1.Text = “01”
Text2.Text = “350000”
Case “SERABAYA-DENPASAR”
Text1.Text = “02”
Text2.Text = “100000”
Case “SERABAYA-BALIKPAPAN”
Text1.Text = “03”
Text2.Text = “400000”
Case “SERABAYA-MEDAN”
Text1.Text = “04”
Text2.Text = “500000”
Case “SERABAYA-LOMBOK”
Text1.Text = “05”
Text2.Text = “150000”
Case “SERABAYA-SOLO”
Text1.Text = “06”
Text2.Text = “100000”
Case “JAKARTA-SURABAYA”
Text1.Text = “07”
Text2.Text = “350000”
Case “DENPASAR-SURABAYA”
Text1.Text = “08”
Text2.Text = “100000”
Case “BALIKPAPAN-SURABAYA”
Text1.Text = “09”
Text2.Text = “400000”
Case “MEDAN-SURABAYA”
Text1.Text = “10”
Text2.Text = “500000”
Case “LOMBOK-SURABAYA”
Text1.Text = “11”
Text2.Text = “150000”
Case “SOLO-SURABAYA”
Text1.Text = “12”
Text2.Text = “100000”
Case “LAMPUNG-JAKARTA”
Text1.Text = “13”
Text2.Text = “300000”
Case “JAKARTA-LAMPUNG”
Text1.Text = “14”
Text2.Text = “300000”
Case Else

End Select
End Sub

Private Sub Combo2_Click()
Select Case Combo2.Text
Case “BISNIS”
Text1.Text =Left ( Text1.Text , 2 ) + “BSN”
Text2.Text = Text2.Text + 50000
Case “EKSEKUTIF”
Text1.Text = Left ( Text1.Text , 2 ) + “EKS”
Text2.Text = Text2.Text + 35000
Case “EKONOMI”
Text1.Text = Left ( Text1.Text , 2 ) + “EKM”
Text2.Text = Text2.Text + 30000
Case Else

End Select

End Sub

Private Sub Combo3_Click()
Select Case Combo3.Text
Case “SERABAYA-JAKARTA”
Text8.Text = “01”
Text9.Text = “350000”
Case “SERABAYA-DENPASAR”
Text8.Text = “02”
Text9.Text = “100000”
Case “SERABAYA-BALIKPAPAN”
Text8.Text = “03”
Text9.Text = “400000”
Case “SERABAYA-MEDAN”
Text8.Text = “04”
Text9.Text = “500000”
Case “SERABAYA-LOMBOK”
Text8.Text = “05”
Text9.Text = “150000”
Case “SERABAYA-SOLO”
Text8.Text = “06”
Text9.Text = “100000”
Case “JAKARTA-SURABAYA”
Text8.Text = “07”
Text9.Text = “350000”
Case “DENPASAR-SURABAYA”
Text8.Text = “08”
Text9.Text = “100000”
Case “BALIKPAPAN-SURABAYA”
Text8.Text = “09”
Text9.Text = “400000”
Case “MEDAN-SURABAYA”
Text8.Text = “10”
Text9.Text = “500000”
Case “LOMBOK-SURABAYA”
Text8.Text = “11”
Text9.Text = “150000”
Case “SOLO-SURABAYA”
Text8.Text = “12”
Text9.Text = “100000”
Case “LAMPUNG-JAKARTA”
Text8.Text = “13”
Text9.Text = “300000”
Case “JAKARTA-LAMPUNG”
Text8.Text = “14”
Text9.Text = “300000”
Case Else

End Select
End Sub

Private Sub Combo4_Click()
Select Case Combo4.Text
Case “BISNIS”
Text8.Text = Left ( Text8.Text , 2 ) + “BSN”
Text10.Text = Text9.Text + 50000
Case “EKSEKUTIF”
Text8.Text = Left ( Text8.Text , 2 )+ “EKS”
Text10.Text = Text9.Text + 35000
Case “EKONOMI”
Text8.Text = Left ( Text8.Text , 2 )+ “EKM”
Text10.Text = Text9.Text + 30000
Case Else
End Select

End Sub

Private Sub Command1_Click()
Data2.Recordset.AddNew
End Sub

Private Sub Command10_Click()
Data3.Recordset.Edit
End Sub

Private Sub Command11_Click()
End
End Sub

Private Sub Command2_Click()
Data2.Recordset.Edit
End Sub

Private Sub Command3_Click()
Data2.Recordset.Update
End Sub
Private Sub Command4_Click()
Data2.Recordset.Delete
Data2.Refresh
End Sub

Private Sub Command6_Click()
Text4.Text = “”
Text5.Text = “”
Text6.Text = “”
Text7.Text = “”
Text8.Text = “”
Text9.Text = “”
Text10.Text = “”
Combo3.Text = “”
Combo4.Text = “”
Combo5.Text = “”
End Sub

Private Sub Command7_Click()
Data3.Recordset.AddNew
End Sub

Private Sub Command8_Click()
Data3.Recordset.Update
End Sub
Private Sub Command9_Click()
Data3.Recordset.Delete
Data3.Refresh
End Sub

Private Sub Form_Load()
Combo1.AddItem “SERABAYA-JAKARTA”
Combo1.AddItem “SERABAYA-DENPASAR”
Combo1.AddItem “SERABAYA-BALIKPAPAN”
Combo1.AddItem “SERABAYA-MEDAN”
Combo1.AddItem “SERABAYA-LOMBOK”
Combo1.AddItem “SERABAYA-SOLO”
Combo1.AddItem “JAKARTA-SURABAYA”
Combo1.AddItem “DENPASAR-SURABAYA”
Combo1.AddItem “BALIKPAPAN-SURABAYA”
Combo1.AddItem “MEDAN-SURABAYA”
Combo1.AddItem “LOMBOK-SURABAYA”
Combo1.AddItem “SOLO-SURABAYA”
Combo1.AddItem “LAMPUNG-JAKARTA”
Combo1.AddItem “JAKARTA-LAMPUNG”

Combo2.AddItem “BISNIS”
Combo2.AddItem “EKSEKUTIF”
Combo2.AddItem “EKONOMI”

Combo3.AddItem “SERABAYA-JAKARTA”
Combo3.AddItem “SERABAYA-DENPASAR”
Combo3.AddItem “SERABAYA-BALIKPAPAN”
Combo3.AddItem “SERABAYA-MEDAN”
Combo3.AddItem “SERABAYA-LOMBOK”
Combo3.AddItem “SERABAYA-SOLO”
Combo3.AddItem “JAKARTA-SURABAYA”
Combo3.AddItem “DENPASAR-SURABAYA”
Combo3.AddItem “BALIKPAPAN-SURABAYA”
Combo3.AddItem “MEDAN-SURABAYA”
Combo3.AddItem “LOMBOK-SURABAYA”
Combo3.AddItem “SOLO-SURABAYA”
Combo3.AddItem “LAMPUNG-JAKARTA”
Combo3.AddItem “JAKARTA-LAMPUNG”

Combo4.AddItem “BISNIS”
Combo4.AddItem “EKSEKUTIF”
Combo4.AddItem “EKONOMI”

Combo5.AddItem “20/02/2012”
Combo5.AddItem “21/02/2012”
Combo5.AddItem “22/02/2012”
Combo5.AddItem “23/02/2012”
Combo5.AddItem “24/02/2012”
Combo5.AddItem “25/02/2012”
Combo5.AddItem “26/02/2012”
Combo5.AddItem “27/02/2012”
Combo5.AddItem “28/02/2012”
Combo5.AddItem “29/02/2012”
Combo5.AddItem “01/03/2012”
Combo5.AddItem “02/03/2012”
Combo5.AddItem “03/03/2012”
Combo5.AddItem “04/03/2012”
End Sub

Tinggalkan Balasan

Isikan data di bawah atau klik salah satu ikon untuk log in:

Logo WordPress.com

You are commenting using your WordPress.com account. Logout / Ubah )

Gambar Twitter

You are commenting using your Twitter account. Logout / Ubah )

Foto Facebook

You are commenting using your Facebook account. Logout / Ubah )

Foto Google+

You are commenting using your Google+ account. Logout / Ubah )

Connecting to %s