'把下面代码放入targe表中运行。
SubABCD()
DimljAsString
DimdirnameAsString
DimnmAsString
lj=ActiveWorkbook.Path
nm=ActiveWorkbook.Name
dirname=Dir(lj&"\*.xls")
Cells.Clear
DoWhiledirname<>""
Ifdirname<>nmThen
Filename=lj&"\"&dirname
SetWb=GetObject(Filename)
Workbooks(nm).Activate
Workbooks(dirname).Sheets(1).Columns("A").Copy
x=Sheets("sheet1").UsedRange.Columns.Count
x=x+Sheets("sheet1").UsedRange.Column-1
Columns(x+1).Select
ActiveSheet.Paste
Application.CutCopyMode=False
Workbooks(dirname).CloseFalse
EndIf
dirname=Dir
Loop
EndSub