views:

66

answers:

0

hello,I am new to vba and I would like to know if can search thru the worksheets, copy and then paste in a new worksheet on a column thank you

Public Sub CopyandPaste() Dim ws As Worksheet

' Delete all data from Summary Page Worksheets("1a").UsedRange.Delete

' Copy each worksheet in file and paste to Summary Page

For Each ws In Worksheets If ws.Name <> "1a" Then ws.Range("a10").Copy Worksheets("1a").Cells(Rows.Count, 1).End(xlUp).Offset(1, 0).PasteSpecial (xlPasteValues) End If Next ws

End Sub

can be inserted?: Cells.Find(What:="word", After:=ActiveCell, LookIn:=xlFormulas, LookAt _ :=xlPart, SearchOrder:=xlByRows, SearchDirection:=xlNext, MatchCase:= _ False, SearchFormat:=False).Activate Selection.Copy