- ©«¤l
- 438
- ¥DÃD
- 67
- ºëµØ
- 0
- ¿n¤À
- 531
- ÂI¦W
- 30
- §@·~¨t²Î
- win7
- ³nÅ骩¥»
- office 2010
- ¾\ŪÅv
- 50
- ©Ê§O
- ¨k
- µù¥U®É¶¡
- 2012-10-30
- ³Ì«áµn¿ý
- 2024-10-24
|
¦^´_ 50# GBKEE
Option Explicit
Sub Ex()
Dim Rng(1 To 2) As Range
With Workbooks("payment.XLSM").Sheets("2012")
Sheets("2012").Range("A2:L65536").ClearContents
Sheets("2012").Range("A2:L65536").Interior.Color = xlNone
.Range("A1").CurrentRegion.Offset(1) = ""
Set Rng(1) = .[e2]
With Workbooks.Open("C:\Documents and Settings\USER\®à±\Connie.XLSX").Sheets("SHEET1")
Set Rng(2) = .[A2:L2]
Set Rng(2) = Rng(2).Resize(.Range("E" & .Rows.Count).End(xlUp).Row - 1)
Rng(2).copy Rng(1).Cells(1, -3)
.Parent.Close False
End With
Set Rng(1) = .Range("E" & .Rows.Count).End(xlUp).Offset(2)
With Workbooks.Open("C:\Documents and Settings\USER\®à±\Lily.XLSX").Sheets("SHEET1")
Set Rng(2) = .[A2:L2]
Set Rng(2) = Rng(2).Resize(.Cells(.Rows.Count, "E").End(xlUp).Row - 1)
Set Rng(2) = Rng(2).Resize(.Range("E" & .Rows.Count).End(xlUp).Row - 1)
Rng(2).copy Rng(1).Cells(1, -3)
.Parent.Close False
End With
Set Rng(1) = .Range("E" & .Rows.Count).End(xlUp).Offset(2)
With Workbooks.Open("C:\Documents and Settings\USER\®à±\Jane.XLSX").Sheets("SHEET1")
Set Rng(2) = .[A2:L2]
Set Rng(2) = Rng(2).Resize(.Cells(.Rows.Count, "E").End(xlUp).Row - 1)
Set Rng(2) = Rng(2).Resize(.Range("E" & .Rows.Count).End(xlUp).Row - 1)
Rng(2).copy Rng(1).Cells(1, -3)
.Parent.Close False
End With
Set Rng(1) = .Range("E" & .Rows.Count).End(xlUp).Offset(2)
With Workbooks.Open("C:\Documents and Settings\USER\®à±\Jenny.XLSX").Sheets("SHEET1")
Set Rng(2) = .[A2:L2]
Set Rng(2) = Rng(2).Resize(.Cells(.Rows.Count, "E").End(xlUp).Row - 1)
Set Rng(2) = Rng(2).Resize(.Range("E" & .Rows.Count).End(xlUp).Row - 1)
Rng(2).copy Rng(1).Cells(1, -3)
.Parent.Close False
End With
Set Rng(1) = .Range("E" & .Rows.Count).End(xlUp).Offset(2)
With Workbooks.Open("C:\Documents and Settings\USER\®à±\Patrick.XLSX").Sheets("SHEET1")
Set Rng(2) = .[A2:L2]
Set Rng(2) = Rng(2).Resize(.Cells(.Rows.Count, "E").End(xlUp).Row - 1)
Set Rng(2) = Rng(2).Resize(.Range("E" & .Rows.Count).End(xlUp).Row - 1)
Rng(2).copy Rng(1).Cells(1, -3)
.Parent.Close False
End With
End With
End Sub
¸g¹L§ï¨}«á¡A¦¨¥\¤F¡A´N¦¨®Ä¼g¥X¨Ó»P¤j®a¤À¨É~~ |
|