TUGAS 3 PEMROGRAMAN 1

TUGAS 1

Private Sub chkitalic_Click()

‘Membuat teks miring’

If chkitalic.Value = 1 Then

Lblteks.FontItalic = True

Else

Lblteks.FontItalic = False

End If

 

End Sub

 

Private Sub chkstrikethru_Click()

‘Membuat teks garis tengah’

If chkstrikethru.Value = 1 Then

Lblteks.FontStrikethru = True

Else

Lblteks.FontStrikethru = False

End If

 

End Sub

Private Sub chkunderline_Click()

‘Membuat teks garis bawah’

If chkunderline.Value = 1 Then

Lblteks.FontUnderline = True

Else

Lblteks.FontUnderline = False

End If

 

End Sub

 

Private Sub Cmdexit_Click()

End

 

End Sub

 

Private Sub optblue_Click()

‘membuat teks berwarna biru’

Lblteks.ForeColor = vbBlue

 

End Sub

 

Private Sub optgreen_Click()

‘membuat teks berwarna hijau’

Lblteks.ForeColor = vbGreen

 

End Sub

 

Private Sub optRed_Click()

‘membuat teks berwarna merah’

Lblteks.ForeColor = vbRed

 

End Sub

 

Private Sub optyellow_Click()

‘membuat teks berwarna kuning’

Lblteks.ForeColor = vbYellow

 

End Sub

Private Sub chkBold_Click()

‘Membuat teks Tebal’

If chkbold.Value = 1 Then

Lblteks.FontBold = True

Else

Lblteks.FontBold = False

End If

 

End Sub

SCREENSHOTS 1

TUGAS 1 SCREN 1

SCRENSHOTS 2

tugas 1 scren 2

TUGAS 2

Private Sub Chkmiring_Click()

‘Membuat teks miring’

If Chkmiring.Value = 1 Then

label2.FontItalic = True

Else

label2.FontItalic = False

End If

End Sub

Private Sub optbiru_Click()

‘membuat teks biru’

label2.ForeColor = vbBlue

End Sub

Private Sub Optmerah_Click()

‘Membuat teks merah’

label2.ForeColor = vbRed

End Sub

Private Sub chktebal_Click()

‘Membuat teks Tebal’

If chktebal.Value = 1 Then

label2.FontBold = True

Else

label2.FontBold = False

End If

End Sub

Private Sub cmdok_Click()

label2.Caption = lebelmm

End Sub

Private Sub cmdselesai_Click()

End

End Sub

SCREENSHOTS 1

tugas 2 scren 1

SCREENSHOTS 2

tugas 2 scren 2

TUGAS 3

Private Sub rdnpm_Click()

Dim nama, jurusan, hm As String

Select Case rdnpm.Text

Case “15100025”

nama = “RAHMAT DARMAWAN”

jurusan = “Sistem Informasi”

Case “15100026”

nama = “REZA ANGGARA”

jurusan = “Sistem Infomasi”

Case “15100002”

nama = “FERGIAWAN LISTIANTO”

jurusan = “Sistem Infomasi”

End Select

rdnm = nama

rdj = jurusan

rdnq.SetFocus

End Sub

Private Sub Cmdbatal_Click()

rdnpm.SetFocus

rdnpm.Text = “”

rdj.Text = “”

rdnq.Text = “”

rdnt.Text = “”

rduts.Text = “”

rduas.Text = “”

rdna.Text = “”

rdnm.Text = “”

Text1.Text = “”

End Sub

Private Sub Cmdkeluar_Click()

End

End Sub

Private Sub cmdproses_click()

Dim na As Integer

Dim hm As String

nq = Val(rdnq.Text)

nt = Val(rdnt.Text)

uts = Val(rduts.Text)

uas = Val(rduas.Text)

na = (nq + nt + uts + uas) / 4

rdna.Text = na

Select Case rdna.Text

Case Is > 80

hm = “A”

Case Is > 70

hm = “B”

Case Is > 60

hm = “C”

Case Is > 50

hm = “D”

Case Is < 50

hm = “E”

End Select

Text1.Text = hm

End Sub

Private Sub form_load()

rdnpm.AddItem “15100025”

rdnpm.AddItem “15100002”

rdnpm.AddItem “15100026”

End Sub

Private Sub rdnq_keypress(keyascii As Integer)

If keyascii = 13 Then

rdnt.SetFocus

End If

End Sub

Private Sub rdnt_keypress(keyascii As Integer)

If keyascii = 13 Then

rduts.SetFocus

End If

End Sub

Private Sub rduts_keypress(keyascii As Integer)

If keyascii = 13 Then

rduas.SetFocus

End If

End

SCREENSHOTS 1

tugas 3 scren 1

SCREENSHOTS 2

tugas 3 scren 2

Tugas 4

Private Sub rdnpm_Click()

Dim nama, jurusan, hm As String

Select Case rdnpm.Text

Case “15100025”

nama = “RAHMAT DARMAWAN”

jurusan = “Sistem Informasi”

Case “15100026”

nama = “REZA ANGGARA”

jurusan = “Sistem Infomasi”

Case “15100002”

nama = “FERGIAWAN LISTIANTO”

jurusan = “Sistem Infomasi”

End Select

rdnm = nama

rdj = jurusan

rdnq.SetFocus

End Sub

Private Sub Cmdbatal_Click()

rdnpm.SetFocus

rdnpm.Text = “”

rdj.Text = “”

rdnq.Text = “”

rdnt.Text = “”

rduts.Text = “”

rduas.Text = “”

rdna.Text = “”

rdnm.Text = “”

text1.Text = “”

rdna.BackColor = vbWhite

text1.BackColor = vbWhite

End Sub

Private Sub Cmdkeluar_Click()

End

End Sub

Private Sub cmdproses_click()

Dim na As Integer

Dim hm As String

nq = Val(rdnq.Text)

nt = Val(rdnt.Text)

uts = Val(rduts.Text)

uas = Val(rduas.Text)

na = Val(Val(nq) + Val(nt) + Val(uts) + Val(uas)) / 4

rdna.Text = na

Select Case rdna.Text

Case Is > 80

hm = “A”

Case Is > 70

hm = “B”

Case Is > 60

hm = “C”

Case Is > 50

hm = “D”

Case Is < 50

hm = “E”

End Select

text1.Text = hm

End Sub

Private Sub form_load()

rdnpm.AddItem “15100025”

rdnpm.AddItem “15100002”

rdnpm.AddItem “15100026”

End Sub

Private Sub rdnq_keypress(keyascii As Integer)

If keyascii = 13 Then

rdnt.SetFocus

End If

End Sub

Private Sub rdnt_keypress(keyascii As Integer)

If keyascii = 13 Then

rduts.SetFocus

End If

End Sub

Private Sub rduas_keypress(keyascii As Integer)

If keyascii = 13 Then

Dim na As Integer

Dim hm As String

rdna = Val(Val(rdnq) + Val(rdnt) + Val(rduts) + Val(rduas)) / 4

Select Case rdna.Text

Case Is > 80

hm = “A”

Case Is > 70

hm = “B”

Case Is > 60

hm = “C”

Case Is > 50

hm = “D”

Case Is < 50

hm = “E”

End Select

text1.Text = hm

End If

End Sub

Private Sub rduts_keypress(keyascii As Integer)

If keyascii = 13 Then

rduas.SetFocus

End If

End Sub

SCREENSHOTS 1

tugas 4 scren 1

SCREENSHOTS 2

tugas 4 scren 2

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Iklan

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 )

Foto Google+

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

w

Connecting to %s