Subcopy_case_Contoh1()
Select Case [a1]
Case 1
[A5:A10].Copy
Case 2
[B5:B10].Copy
Case 3
[C5:C10].Copy
Case 4
[D5:D10].Copy
Case 5
[E5:E10].Copy
End Select
Sheets("Sheet2").Cells(Cells.Rows.Count, 1).End(xlUp).Offset(2, 0).PasteSpecial Paste:=xlPasteValues
Sheets("Sheet2").Select
End Sub
Subcopy_case_Contoh2()
Select Case [a1]
Case 1
[a5:c10].Copy Sheet1.[d5]
Case 2
[a5:c10].Copy Sheet1.[e5]
Case 3
[a5:c10].Copy Sheet1.[f5]
Case 4
[a5:c10].Copy Sheet1.[g5]
Case 5
[a5:c10].Copy Sheet1.[h5]
End Select
End Sub
Select Case [a1]
Case 1
[A5:A10].Copy
Case 2
[B5:B10].Copy
Case 3
[C5:C10].Copy
Case 4
[D5:D10].Copy
Case 5
[E5:E10].Copy
End Select
Sheets("Sheet2").Cells(Cells.Rows.Count, 1).End(xlUp).Offset(2, 0).PasteSpecial Paste:=xlPasteValues
Sheets("Sheet2").Select
End Sub
Subcopy_case_Contoh2()
Select Case [a1]
Case 1
[a5:c10].Copy Sheet1.[d5]
Case 2
[a5:c10].Copy Sheet1.[e5]
Case 3
[a5:c10].Copy Sheet1.[f5]
Case 4
[a5:c10].Copy Sheet1.[g5]
Case 5
[a5:c10].Copy Sheet1.[h5]
End Select
End Sub
DEMIKIAN SEMOGA BERMANFAAT
No comments:
Post a Comment