Hi,
How would i copy contents of cell B4 for every sheet (except summary) to cell column A on the summary sheet ?
Hi,
How would i copy contents of cell B4 for every sheet (except summary) to cell column A on the summary sheet ?
Last edited by jsmity; 01-21-2013 at 10:33 AM. Reason: solved
This should do it
![]()
Sub abc() Const shSummary As String = "Summary" Dim ws As Worksheet Dim aArr As Variant Dim i As Long ReDim aArr(1 To Worksheets.Count - 1, 1 To 2) For Each ws In Worksheets With ws If .Name <> shSummary Then i = i + 1 aArr(i, 1) = .Cells(4, "b").Value aArr(i, 2) = .Cells(6, "b").Value End If End With Next With Worksheets(shSummary) .Cells.Delete .Cells(1, "a").Resize(, 2) = [{"Recipe Name", "Recipe Number"}] .Cells(2, "a").Resize(UBound(aArr), 2) = aArr End With End Sub
Last edited by mike7952; 01-21-2013 at 10:14 AM.
Thanks,
Mike
If you are satisfied with the solution(s) provided, please mark your thread as Solved.
Select Thread Tools-> Mark thread as Solved.
Thanks works
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks