+ Reply to Thread
Results 1 to 5 of 5

Macro is copying and pasting into cell A2 on new sheet instead of cell A1 Please Help!

  1. #1
    Registered User
    Join Date
    02-29-2012
    Location
    sanford, fl
    MS-Off Ver
    Excel 2007
    Posts
    21

    Macro is copying and pasting into cell A2 on new sheet instead of cell A1 Please Help!

    I am hoping someone can help me; I have a macro that copies all my sheets onto a new sheet called combine. It is pasting onto the combine sheet starting on cell A2 instead of cell A1. Can anyone tell me why? Following is my macro. Thank you

    Sub Combine()
    Dim J As Integer
    Sheets(1).Select
    Worksheets.Add
    Sheets(1).Name = "Combined"
    On Error Resume Next
    For J = 2 To Sheets.Count
    Sheets(J).Activate
    Range("A1").Select
    Selection.CurrentRegion.Select
    Selection.Copy Destination:=Sheets("Combined").Cells(Rows.Count, 1).End(xlUp)(2)
    Next
    End Sub

  2. #2
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Macro is copying and pasting into cell A2 on new sheet instead of cell A1 Please Help!

    Please use code tags when posting. Since you are copying multiple sheets, I assume you want to offset to the next unused cell in Column A on each iteration. By default Excel assumes row 1 is a header. A workaround is posted below.

    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    02-29-2012
    Location
    sanford, fl
    MS-Off Ver
    Excel 2007
    Posts
    21

    Re: Macro is copying and pasting into cell A2 on new sheet instead of cell A1 Please Help!

    Thank you for your help. That worked perfectly.

  4. #4
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Macro is copying and pasting into cell A2 on new sheet instead of cell A1 Please Help!

    You're welcome. Glad to help out and thanks for the feedback. Please comply with Forum Rule No. 9.


    9. Acknowledge the responses you receive, good or bad. If your problem is solved, please say so clearly, and mark your thread as Solved: Click Thread Tools above your first post, select "Mark your thread as Solved". Or click the Edit button on your first post in the thread, Click Go Advanced, select [SOLVED] from the Prefix dropdown, then click Save Changes. If more than two days have elapsed, the Dropdown option or Edit button will not appear -- ask a moderator to mark it.

  5. #5
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: Macro is copying and pasting into cell A2 on new sheet instead of cell A1 Please Help!

    You're welcome. Glad to help out and thanks for the feedback. Please comply with Forum Rule No. 9.


    9. Acknowledge the responses you receive, good or bad. If your problem is solved, please say so clearly, and mark your thread as Solved: Click Thread Tools above your first post, select "Mark your thread as Solved". Or click the Edit button on your first post in the thread, Click Go Advanced, select [SOLVED] from the Prefix dropdown, then click Save Changes. If more than two days have elapsed, the Dropdown option or Edit button will not appear -- ask a moderator to mark it.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Copying a cell and pasting to next sheet according the last used row of previous column.
    By apla in forum Excel Programming / VBA / Macros
    Replies: 17
    Last Post: 09-26-2013, 11:43 AM
  2. Macro for copying cell valus from one worksheet and pasting in other worksheets
    By Jarkova in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-21-2013, 11:48 PM
  3. Copying one cell's content and pasting it in the same row and column in another sheet
    By fischbroetchen in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 02-12-2013, 04:04 PM
  4. Using a macro to copying data from 1 sheet, and pasting into next empty cell
    By Varial in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-13-2012, 04:05 PM
  5. [SOLVED] Create a Macro for copying data from one cell and pasting into certain part other cell
    By Paul M in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 12-03-2012, 10:17 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1