(资料图片)
1、Sub 合并工作表() Dim MyPath$, MyName$ Application.ScreenUpdating = False MyPath = ActiveWorkbook.Path & "" MyName = Dir(MyPath & "*.xls") On Error Resume Next Do While MyName <> "" If MyName <> ***.Name Then With GetObject(MyPath & MyName) .Sheets("newSheet").Copy After:=ActiveWorkbook.Sheets(ActiveWorkbook.Sheets.Count) End With End If MyName = Dir Loop Application.ScreenUpdating = TrueEnd Sub。
本文分享完毕,希望对你有所帮助。
关键词: