Materi Perkuliahan

KELILING PERSEGI DAN PERSEGI PANJANG (VBA EXCEL)

Dipublikasikan pada : 29 Januari 2019.

Sub acak()
Range(“C11”) = Int(50 * Rnd()) + 1
Range(“N11”) = Range(“C11”)
Range(“G6”) = Int(50 * Rnd()) + 50
Range(“G16”) = Range(“G6”)
Range(“W11”) = Int(100 * Rnd()) + 1
Range(“AA17”) = Range(“W11”)
Range(“AE11”) = Range(“W11”)
Range(“AA5”) = Range(“W11”)
End Sub
Sub keliling_persegi_panjang()
Range(“E25”) = Range(“G6”)
Range(“G25”) = Range(“G6”)
Range(“I25”) = Range(“C11”)
Range(“K25”) = Range(“C11”)
Range(“E27”) = “2”
Range(“G27”) = Range(“G6”)
Range(“I27”) = “2”
Range(“K27”) = Range(“C11”)
Range(“E29”) = “2”
Range(“H29”) = Range(“G6”)
Range(“J29”) = Range(“C11”)
Range(“M25”) = 2 * (Range(“G6”) + Range(“C11”))
Range(“M27”) = Range(“M25”)
Range(“M29”) = Range(“M25”)
End Sub
Sub keliling_persegi()
Range(“U24”) = Range(“W11”)
Range(“W24”) = Range(“W11”)
Range(“Y24”) = Range(“W11”)
Range(“AA24”) = Range(“W11”)
Range(“AA26”) = Range(“W11”)
Range(“Y26”) = “4”
Range(“AC24”) = 4 * Range(“W11”)
Range(“AC26”) = Range(“AC24”)
End Sub
Sub CM_KE_M()
Range(“P25”) = Range(“M25”) / 100
Range(“AF24”) = Range(“AC26”) / 100
End Sub
Sub JAWABAN_TERLIHAT()
Range(“E25”, “P29”).Interior.Color = vbGreen
Range(“U24”, “AF26”).Interior.Color = vbYellow
End Sub
Sub jawaban_tak_terlihat()
Range(“E25”, “P29”).Interior.Color = vbBlack
Range(“U24”, “AF26”).Interior.Color = vbBlack
End Sub
Sub hapus()
Range(“C11”) = “”
Range(“N11”) = “”
Range(“G6”) = “”
Range(“G16”) = “”
Range(“W11”) = “”
Range(“AA17”) = “”
Range(“AE11”) = “”
Range(“AA5”) = “”
Range(“U24”) = “”
Range(“W24”) = “”
Range(“Y24”) = “”
Range(“AA24”) = “”
Range(“AA26”) = “”
Range(“AC24”) = “”
Range(“AC26”) = “”
Range(“Y26”) = “”
Range(“AF24”) = “”
Range(“E27”) = “”
Range(“I27”) = “”
Range(“G27”) = “”
Range(“K27”) = “”
Range(“E25”) = “”
Range(“G25”) = “”
Range(“I25”) = “”
Range(“K25”) = “”
Range(“E29”) = “”
Range(“H29”) = “”
Range(“J29”) = “”
Range(“M25”) = “”
Range(“M27”) = “”
Range(“M29”) = “”
Range(“P25”) = “”
Range(“e21”) = “”
Range(“e19”) = “”
Range(“e23”) = “”
Range(“g21”) = “”
Range(“G19”) = “”
Range(“I21”) = “”
Range(“I19”) = “”
Range(“K21”) = “”
Range(“K19”) = “”
Range(“M21”) = “”
Range(“M19”) = “”
Range(“M23”) = “”
Range(“H23”) = “”
Range(“J23”) = “”
Range(“P19”) = “”
Range(“U20”) = “”
Range(“W20”) = “”
Range(“Y20”) = “”
Range(“AA20”) = “”
Range(“AC20”) = “”
Range(“Y22”) = “”
Range(“AA22”) = “”
Range(“AC22”) = “”
Range(“AF20”) = “”

End Sub

[gview file=”https://dosen.ikipsiliwangi.ac.id/wp-content/uploads/sites/6/2019/01/langkah2-aplikasi-tugas-uas-tiya-fitriani-14510193.doc”]