+ Reply to Thread
Results 1 to 3 of 3

Help with copying rows to another sheet based on value

  1. #1
    Registered User
    Join Date
    05-09-2011
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    2

    Help with copying rows to another sheet based on value

    Hello all,

    Total code noob here, but I need some help copying data in my worksheet. Basically, I have a bunch of box office ticket prices in one column and then the number of those tickets in another along with a bunch of other columns that I would like copied over as well. So:

    A (price) B (ticket number) C,D etc.

    1| $10 2


    Now how would I copy row 1 through x to a new sheet so that the row is copied based on the number of tickets. So new sheet 2:

    A (price) B (ticket number) C,D etc.

    1| $10 (doesn't matter) (same as sheet 1)

    2| $10 (doesn't matter) (same as sheet 1)

    Hopefully that is clear and thanks for the help, I have a bunch of data to analyze and this would greatly help me out!

    Ash

  2. #2
    Forum Expert
    Join Date
    07-31-2010
    Location
    California
    MS-Off Ver
    Excel 2007
    Posts
    4,070

    Re: Help with copying rows to another sheet based on value

    Quick and dirty:

    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    05-09-2011
    Location
    London
    MS-Off Ver
    Excel 2010
    Posts
    2

    Re: Help with copying rows to another sheet based on value

    Thanks for the quick response! I am using Excel 2004 for Mac FYI and I had a runtime error when I ran the module with the line as an overflow:

    rCount = icell.Offset(0, 1).Value

    Any more help would be awesome. Just to reiterate, i have a bunch of rows of data with a quantity column at the end, and I would like each row to copy to a new sheet as many times as the quantity indicates. So if row 1 has a quantity of 2, it should copy to two rows on the new sheet.

    thanks!

+ 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