您好,欢迎访问三七文档
ͬһÎļþ¼Ð϶à¸ö¹¤×÷²¾ÄÚÈÝ»ã×ܵ½ÁíÒ»¹¤×÷²¾Ò»ÕŹ¤×÷±íÄÚ£¨·½·¨Ò»£©£ºSubMacro1()DimMyPath$,MyName$,shAsWorksheet,shtAsWorksheet,m&Setsh=ActiveSheetMyPath=ThisWorkbook.Path&\MyName=Dir(MyPath&*.xls)Application.ScreenUpdating=FalseCells.ClearContentsDoWhileMyNameIfMyNameThisWorkbook.NameThenWithGetObject(MyPath&MyName)ForEachshtIn.SheetsIfIsSheetEmpty=IsEmpty(sht.UsedRange)Thenm=m+1Ifm=1Thensht.[a1].CurrentRegion.Copysh.[a1]Elsesht.[a1].CurrentRegion.Offset(1).Copysh.[a65536].End(xlUp).Offset(1)EndIfEndIfNext.CloseFalseEndWithEndIfMyName=DirLoopApplication.ScreenUpdating=TrueEndSub×¢£ºÃ»ÓпÕÐУ¬Ã»Óй¤×÷²¾Ãû³Æ½ø»ã×Ü±í£¬²»¹Üµã¼¸´ÎºêÔËÐУ¬¶¼Ö»»ã×ÜÒ»´ÎÄÚÈÝ¡£
本文标题:如何利用excel2003将同一文件夹下多个工作簿内容汇总到另一工作簿一张工作表内(方法一)
链接地址:https://www.777doc.com/doc-5563928 .html