+ Reply to Thread
Results 1 to 4 of 4

copy sheet to new worksheet

  1. #1
    Registered User
    Join Date
    10-19-2009
    Location
    singapore
    MS-Off Ver
    2010,2013
    Posts
    45

    Exclamation copy sheet to new worksheet

    any one can help ? here is my code when it reaches red line code.i encounter 400 error.
    my logic is this, copy sheet1 column A1 data and paste at sheet 2 column G1.

    Please Login or Register  to view this content.

  2. #2
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,612

    Re: copy sheet to new worksheet

    Issue one:
    lastrow = .Cells(.Columns.count, "A").End(xlUp).Row --> lastrow = .Cells(.Rows.count, "A").End(xlUp).Row will give you the last row in column A

    2. RowsWithNumbers.EntireRow.copy Destination.Range("G1") Entire row does not match Cell G1 (i.e., size); did you mean to insert a row?
    Ben Van Johnson

  3. #3
    Registered User
    Join Date
    10-23-2009
    Location
    USA
    MS-Off Ver
    Excel 2003, 2007, 2010
    Posts
    75

    Re: copy sheet to new worksheet

    Hay I am still learning but this is what I did, On my sheet
    BOM is primary sheet Fasteners is secondary.
    If fasterner work sheet exists get a popup for new worksheet name.
    My poplate was colored rows that I ID parts into catagorys

    NOTE: On mine I copyed the Column format to the new page and also did a sort..

    MB



    Please Login or Register  to view this content.
    Last edited by MBCMDR; 11-06-2009 at 01:49 AM. Reason: added note

  4. #4
    Registered User
    Join Date
    10-19-2009
    Location
    singapore
    MS-Off Ver
    2010,2013
    Posts
    45

    Re: copy sheet to new worksheet

    Quote Originally Posted by protonLeah View Post


    2. RowsWithNumbers.EntireRow.copy Destination.Range("G1") Entire row does not match Cell G1 (i.e., size); did you mean to insert a row?
    yep, sample logic is i would like to copy colA from sheet1 to colG in sheet2.

    if i change back to A1 everything work fine. just that i can't copy to "G1"
    Please Login or Register  to view this content.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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