Sub biao1TObiao2() Sheets("Sheet1").Select Range("A1").Select Range(Selection, Selection.End(xlToRight)).Select Range(Selection, Selection.End(xlDown)).Select n1 = Selection.Rows.Count + 1 Selection.Copy Sheets("Sheet2").Select n2 = Application.CountA(Range("A:A")) Range("D2").Select Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _ :=False, Transpose:=False Application.CutCopyMode = False If n1 > n2 Then Range("A" & n2 & ":C" & n2).Select Selection.AutoFill Destination:=Range("A" & n1 & ":C" & n2) End If If n1 < n2 Then Range(n1 + 1 & ":" & n2).Delete End Sub