NAMA            : IDA RIANTIKA

NPM               : 13100058

 

 

PERKALIAN DUA BILANGAN

1

Private Sub Command1_Click()

Text3.Text = Val(Text1.Text) * Val(Text2.Text)

End Sub

 

Private Sub Command2_Click()

Text1.Text = “”

Text2.Text = “”

Text3.Text = “”

 

End Sub

 

Private Sub Command3_Click()

Unload Me

End Sub

 

PROGRAM KALKULATOR

2

Private Sub Command1_Click()

Text4.Text = Val(Text1.Text) + Val(Text2.Text) + Val(Text3.Text)

End Sub

 

Private Sub Command2_Click()

Text4.Text = Val(Text1.Text) * Val(Text2.Text) * Val(Text3.Text)

 

End Sub

 

Private Sub Command3_Click()

Text4.Text = Val(Text1.Text) / Val(Text2.Text) / Val(Text3.Text)

 

End Sub

 

Private Sub Command4_Click()

Text4.Text = Val(Text1.Text) – Val(Text2.Text) – Val(Text3.Text)

 

End Sub

 

Private Sub Command5_Click()

Unload Me

End Sub

 

Private Sub Command6_Click()

Text1.Text = “”

Text2.Text = “”

Text3.Text = “”

Text4.Text = “”

Text1.SetFocus

End Sub

 

Private Sub Command7_Click()

Text1.Text = “”

Text2.Text = “”

Text3.Text = “”

Text4.Text = “”

Text1.SetFocus

 

End Sub

 

Private Sub Form_Load()

 

End Sub

 

 

 

 

PROGRAM FONT STYLE

3

Private Sub Check1_Click()

If Check1.Value = 1 Then

Label1.FontBold = True

Else

Label1.FontBold = False

End If

End Sub

 

Private Sub Check2_Click()

If Check2.Value = 1 Then

Label1.FontUnderline = True

Else

Label1.FontUnderline = False

End If

End Sub

 

Private Sub Check3_Click()

If Check3.Value = 1 Then

Label1.FontItalic = True

Else

Label1.FontItalic = False

End If

End Sub

 

Private Sub Check4_Click()

If Check4.Value = 1 Then

Label1.FontStrikethru = True

Else

Label1.FontStrikethru = False

End If

End Sub

 

Private Sub Command1_Click()

Unload Me

End Sub

 

Private Sub Form_Load()

 

End Sub

 

Private Sub Option1_Click()

Label1.ForeColor = vbRed

End Sub

 

Private Sub Option2_Click()

Label1.ForeColor = vbBlue

End Sub

 

Private Sub Option3_Click()

Label1.ForeColor = vbGreen

End Sub

 

Private Sub Option4_Click()

Label1.ForeColor = vbyellow

End Sub

 

 

 

 

DISKON

4

Private Sub Command1_Click()

Text3.Text = Val(Text1.Text) – Val(Text2.Text)

End Sub

 

 

 

Private Sub Command2_Click()

Text1.Text = “”

Text2.Text = “”

Text3.Text = “”

Text1.SetFocus

 

End Sub

 

Private Sub Command3_Click()

Unload Me

End Sub

 

Private Sub Form_Load()

 

End Sub

 

Private Sub Text2_Click()

Text2.Text = (Val(Text1.Text) * (0.1))

End Sub

 

 

APLIKASI GAJI

5

Private Sub Command1_Click()

Text2.Text = Val(Text1.Text) * 0.5

 

Text3.Text = Val(Text1.Text) * 0.1

 

Text4.Text = (Val(Text1.Text) + Val(Text2.Text)) – Val(Text3.Text)

 

Text5.Text = Val(Text4.Text) * 0.1

 

Text6.Text = Val(Text4.Text) – Val(Text5.Text)

 

End Sub

 

Private Sub Command2_Click()

Text1.Text = “”

Text2.Text = “”

Text3.Text = “”

Text4.Text = “”

Text5.Text = “”

Text6.Text = “”

Text1.SetFocus

End Sub

 

Private Sub Command3_Click()

Unload Me

End Sub

 

Private Sub Form_Load()

 

End Sub