Cape rasanya kalo harus hapus per sheet, lebih enak pake looping sheet name nya di array kan terlebih dahulu.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73
|
Sub HAPUSAALL() Application.ScreenUpdating = False Sheets("InputNilai").Select ActiveSheet.Range("$A$7:$L$611").AutoFilter Field:=12 Range("C8:K607").Select Selection.ClearContents Sheets("Pengaturan").Select Range("D3:E15").Select Selection.ClearContents Range("I3:I15").Select Selection.ClearContents Range("F21:F29").Select Selection.ClearContents Range("F33:F41").Select Selection.ClearContents Sheets("Master SKS").Select Range("W7:W28").Select Selection.ClearContents Range("AA7:AA28").Select Selection.ClearContents Dim MyArray(1 To 39) As String MyArray(1) = "ArabLisan" MyArray(2) = "InggrisLisan" MyArray(3) = "FiqhLisan" MyArray(4) = "BahasaArab" MyArray(5) = "Nahwu" MyArray(6) = "Tashrif" MyArray(7) = "Shorof" MyArray(8) = "Tafsir" MyArray(9) = "IlmuQuran" MyArray(10) = "Hadits" MyArray(11) = "M.Hadits" MyArray(12) = "Faroid" MyArray(13) = "Fiqh" MyArray(14) = "UsulFiqh" MyArray(15) = "Tarikh" MyArray(16) = "Mahfudzot" MyArray(17) = "Tauhid" MyArray(18) = "Imla" MyArray(19) = "Tajwid" MyArray(20) = "Tarbiyah" MyArray(21) = "Balagoh" MyArray(22) = "Mantiq" MyArray(23) = "Mutholaah" MyArray(24) = "Khot" MyArray(25) = "Inggris" MyArray(26) = "Grammer" MyArray(27) = "Indonesia" MyArray(28) = "IPS" MyArray(29) = "Geografi" MyArray(30) = "Ekonomi" MyArray(31) = "Sejarah" MyArray(32) = "IPA" MyArray(33) = "Fisika" MyArray(34) = "Biologi" MyArray(35) = "Kimia" MyArray(36) = "Matematika" MyArray(37) = "Pkn" MyArray(38) = "TIK" MyArray(39) = "Sosiologi"
For i = 1 To UBound(MyArray) Sheets(MyArray(i)).Select ActiveSheet.Range("$A$8:$H$609").AutoFilter Field:=4 Range("E10:H608").Select Selection.ClearContents Next i Application.ScreenUpdating = True End Sub
|