+ Reply to Thread
Results 1 to 5 of 5

i need help

  1. #1
    Registered User
    Join Date
    10-13-2005
    Posts
    4

    i need help

    i have 6 columns of data, A3:A550, B3:B550, C3:C550, D3:D550,E3:E550 AND J3:J550, they are in a sheet called GRAD (2), I want o copy and past these data in to sheet2 . but i want the data in each row to be copied 4 times so i will have 6 colums of data 2200 rows down.

    hope some one can help

  2. #2
    JNW
    Guest

    RE: i need help

    This should do it. Change the references as needed. Also I only got 2192
    rows because the ranges start with a3.

    Sub CopyAndPaste()
    Sheets("sheet1").Range("A3:E550").Copy
    Sheets("sheet2").Range("A1").PasteSpecial
    Set destRng1 = Sheets("sheet2").Cells(Rows.Count, "A").End(xlUp)(2)
    destRng1.PasteSpecial
    Set destRng1 = Sheets("sheet2").Cells(Rows.Count, "A").End(xlUp)(2)
    destRng1.PasteSpecial
    Set destRng1 = Sheets("sheet2").Cells(Rows.Count, "A").End(xlUp)(2)
    destRng1.PasteSpecial
    Application.CutCopyMode = False

    Sheets("sheet1").Range("J3:J550").Copy
    Sheets("sheet2").Range("F1").PasteSpecial '<change the destinations as
    needed
    Set destRng1 = Sheets("sheet2").Cells(Rows.Count, "F"). _
    End(xlUp)(2) 'change row letter as needed
    destRng1.PasteSpecial
    Set destRng1 = Sheets("sheet2").Cells(Rows.Count, "F"). _
    End(xlUp)(2) 'change row letter as needed
    destRng1.PasteSpecial
    Set destRng1 = Sheets("sheet2").Cells(Rows.Count, "F"). _
    End(xlUp)(2) 'change row letter as needed
    destRng1.PasteSpecial
    Application.CutCopyMode = False
    End Sub
    "covi2k2" wrote:

    >
    > i have 6 columns of data, A3:A550, B3:B550, C3:C550, D3:D550,E3:E550 AND
    > J3:J550, they are in a sheet called GRAD (2), I want o copy and past
    > these data in to sheet2 . but i want the data in each row to be copied
    > 4 times so i will have 6 colums of data 2200 rows down.
    >
    > hope some one can help
    >
    >
    > --
    > covi2k2
    > ------------------------------------------------------------------------
    > covi2k2's Profile: http://www.excelforum.com/member.php...o&userid=28078
    > View this thread: http://www.excelforum.com/showthread...hreadid=475839
    >
    >


  3. #3
    Don Guillett
    Guest

    Re: i need help

    you could use a copy/paste macro 4 times.something like this

    for i=1 to 4
    x=cells(rows.count,"a").end(xlup).row+1
    range("a3:e5550,j3:j550)").copy range("a"&x)
    next

    --
    Don Guillett
    SalesAid Software
    [email protected]
    "covi2k2" <[email protected]> wrote in
    message news:[email protected]...
    >
    > i have 6 columns of data, A3:A550, B3:B550, C3:C550, D3:D550,E3:E550 AND
    > J3:J550, they are in a sheet called GRAD (2), I want o copy and past
    > these data in to sheet2 . but i want the data in each row to be copied
    > 4 times so i will have 6 colums of data 2200 rows down.
    >
    > hope some one can help
    >
    >
    > --
    > covi2k2
    > ------------------------------------------------------------------------
    > covi2k2's Profile:

    http://www.excelforum.com/member.php...o&userid=28078
    > View this thread: http://www.excelforum.com/showthread...hreadid=475839
    >




  4. #4
    JNW
    Guest

    Re: i need help

    I knew there had to be an easier way

    "Don Guillett" wrote:

    > you could use a copy/paste macro 4 times.something like this
    >
    > for i=1 to 4
    > x=cells(rows.count,"a").end(xlup).row+1
    > range("a3:e5550,j3:j550)").copy range("a"&x)
    > next
    >
    > --
    > Don Guillett
    > SalesAid Software
    > [email protected]
    > "covi2k2" <[email protected]> wrote in
    > message news:[email protected]...
    > >
    > > i have 6 columns of data, A3:A550, B3:B550, C3:C550, D3:D550,E3:E550 AND
    > > J3:J550, they are in a sheet called GRAD (2), I want o copy and past
    > > these data in to sheet2 . but i want the data in each row to be copied
    > > 4 times so i will have 6 colums of data 2200 rows down.
    > >
    > > hope some one can help
    > >
    > >
    > > --
    > > covi2k2
    > > ------------------------------------------------------------------------
    > > covi2k2's Profile:

    > http://www.excelforum.com/member.php...o&userid=28078
    > > View this thread: http://www.excelforum.com/showthread...hreadid=475839
    > >

    >
    >
    >


  5. #5
    Don Guillett
    Guest

    Re: i need help

    glad to help

    --
    Don Guillett
    SalesAid Software
    [email protected]
    "JNW" <[email protected]> wrote in message
    news:[email protected]...
    > I knew there had to be an easier way
    >
    > "Don Guillett" wrote:
    >
    > > you could use a copy/paste macro 4 times.something like this
    > >
    > > for i=1 to 4
    > > x=cells(rows.count,"a").end(xlup).row+1
    > > range("a3:e5550,j3:j550)").copy range("a"&x)
    > > next
    > >
    > > --
    > > Don Guillett
    > > SalesAid Software
    > > [email protected]
    > > "covi2k2" <[email protected]> wrote

    in
    > > message news:[email protected]...
    > > >
    > > > i have 6 columns of data, A3:A550, B3:B550, C3:C550, D3:D550,E3:E550

    AND
    > > > J3:J550, they are in a sheet called GRAD (2), I want o copy and past
    > > > these data in to sheet2 . but i want the data in each row to be copied
    > > > 4 times so i will have 6 colums of data 2200 rows down.
    > > >
    > > > hope some one can help
    > > >
    > > >
    > > > --
    > > > covi2k2

    > >

    > ------------------------------------------------------------------------
    > > > covi2k2's Profile:

    > > http://www.excelforum.com/member.php...o&userid=28078
    > > > View this thread:

    http://www.excelforum.com/showthread...hreadid=475839
    > > >

    > >
    > >
    > >




+ 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