|
下記のマクロをもう少し簡単にすること出来ますでしょうか。
Sub 担当者別()
'
' 担当者別 Macro
' 未収入金 販売
'
'
Sheets(Array("○", "×", "丸々", "★", "星", "■", "♪")).Select
Sheets("○").Activate
Rows("1:400").Select
Selection.Interior.ColorIndex = xlNone
Selection.ClearContents
Range("A2").Select
Sheets("販売").Select
Selection.AutoFilter
Selection.AutoFilter Field:=12, Criteria1:="○"
Cells.Select
Range("F1").Activate
Selection.Copy
Sheets("○").Select
Range("A1").Select
ActiveSheet.Paste
Application.CutCopyMode = False
Sheets("販売").Select
Selection.AutoFilter Field:=12, Criteria1:="×"
Selection.Copy
Sheets("×").Select
Range("A1").Select
ActiveSheet.Paste
Application.CutCopyMode = False
Range("A1").Select
Sheets("○").Select
Range("A1").Select
Sheets("販売").Select
Selection.AutoFilter Field:=12, Criteria1:="丸々"
Selection.Copy
Sheets("丸々").Select
Range("A1").Select
ActiveSheet.Paste
Application.CutCopyMode = False
Range("A1").Select
Sheets("販売").Select
Selection.AutoFilter Field:=12, Criteria1:="★"
Selection.Copy
Sheets("★").Select
Range("A1").Select
ActiveSheet.Paste
Application.CutCopyMode = False
Range("A1").Select
Sheets("販売").Select
Selection.AutoFilter Field:=12, Criteria1:="星"
Selection.Copy
Sheets("星").Select
Range("A1").Select
ActiveSheet.Paste
Application.CutCopyMode = False
Range("A1").Select
Sheets("販売").Select
Selection.AutoFilter Field:=12, Criteria1:="■"
Selection.Copy
Sheets("■").Select
Range("A1").Select
ActiveSheet.Paste
Application.CutCopyMode = False
Range("A1").Select
Sheets("販売").Select
Selection.AutoFilter Field:=12, Criteria1:="♪"
Selection.Copy
Sheets("♪").Select
Range("A1").Select
ActiveSheet.Paste
Application.CutCopyMode = False
Range("A1").Select
Sheets("販売").Select
Range("A1").Select
Selection.AutoFilter
MsgBox "担当者別にしました"
End Sub
宜しくお願い致します。
|
|