+ Reply to Thread
Results 1 to 8 of 8

COPY/PASTE Issue!!!

Hybrid View

JamesGoulding85 COPY/PASTE Issue!!! 07-11-2013, 05:05 AM
ragulduy Re: COPY/PASTE Issue!!! 07-11-2013, 05:16 AM
blue.chio Re: COPY/PASTE Issue!!! 07-11-2013, 05:16 AM
JamesGoulding85 Re: COPY/PASTE Issue!!! 07-11-2013, 07:21 AM
JosephP Re: COPY/PASTE Issue!!! 07-11-2013, 07:26 AM
JamesGoulding85 Re: COPY/PASTE Issue!!! 07-11-2013, 07:40 AM
JosephP Re: COPY/PASTE Issue!!! 07-11-2013, 07:46 AM
JamesGoulding85 Re: COPY/PASTE Issue!!! 07-11-2013, 07:47 AM
  1. #1
    Registered User
    Join Date
    05-31-2013
    Location
    England
    MS-Off Ver
    Excel 2003
    Posts
    83

    COPY/PASTE Issue!!!

    Hi Folks I know this will be an easy one! im trying to copy a range A1:B(bottom of column) onto another work sheet from A9 down.

    ive got this code

    Worksheets("BCIS").Range("A1:B" & Range("B2").End(xlDown).Row).Copy
                Worksheets(3).Range("A9:B" & Range("B2").End(xlDown).Row).PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks:=False, Transpose:=False
    But it keeps saying that im not copying into the same size range and it wont work.

    Please help

    Thanks

  2. #2
    Forum Expert
    Join Date
    04-22-2013
    Location
    .
    MS-Off Ver
    .
    Posts
    4,418

    Re: COPY/PASTE Issue!!!

    You can't copy A1:B(bottom of column) to a cell that isn't in row 1. Try using:
    Worksheets("BCIS").Range("A1:B" & Range("B" & rows.count).End(xlup).Row).Copy
                Worksheets(3).Range("A9").PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks:=False, Transpose:=False
    to copy only the used range

  3. #3
    Forum Contributor
    Join Date
    03-14-2012
    Location
    location
    MS-Off Ver
    Excel 2007
    Posts
    170

    Re: COPY/PASTE Issue!!!

    perhaps something like this
    Worksheets("Sheet1").Range("A1:B" & Range("B2").End(xlDown).Row).Copy
                Worksheets(3).Range("A9").PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks:=False, Transpose:=False
    Application.CutCopyMode = False
    blue

  4. #4
    Registered User
    Join Date
    05-31-2013
    Location
    England
    MS-Off Ver
    Excel 2003
    Posts
    83

    Re: COPY/PASTE Issue!!!

    Thanks for the posts,

    Yudlugur - your code seems to only copy a few items rather than the whole range.

    Blue.chio - yours still produces the same error message

    error.jpg


    If it helps the whole range is A1:B170 but that range could alter which is why I wanted to use the xldown function (which I assume is the function that goes to the bottom row?)

    any other ideas


    Thanks

  5. #5
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: COPY/PASTE Issue!!!

    perhaps
    With Worksheets("BCIS")
       .Range("A1:B" & .cells(.rows.count, "B").end(xlup).Row).Copy
    End With
       Worksheets(3).Range("A9").PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks:=False, Transpose:=False
    Josie

    if at first you don't succeed try doing it the way your wife told you to

  6. #6
    Registered User
    Join Date
    05-31-2013
    Location
    England
    MS-Off Ver
    Excel 2003
    Posts
    83

    Re: COPY/PASTE Issue!!!

    JosephP - Nailed it cheers mate

  7. #7
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: COPY/PASTE Issue!!!

    you're welcome :-)

    please don't forget to mark the thread solved

  8. #8
    Registered User
    Join Date
    05-31-2013
    Location
    England
    MS-Off Ver
    Excel 2003
    Posts
    83

    Re: COPY/PASTE Issue!!!

    How do I mark a post as solved???

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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