A
AlanN
I was wondering if someone could help me with a macro to cut down on some repetitive task activity.
I have a regularly increasing DB of address information in Excel with several hundred entries with row 1 as the header row. Depending on the demand, we have to create mail labels in various quantities per address, consecutively. I foresee a macro that when kicked off will prompt the user to enter in the number of labels for each row and then duplicate each unique row that number of times (except the header row, of course).
It would be best if it creates the duplicate row list on another sheet. There is only 1 sheet in the workbook as it stands.
For example:
Name Addr1 Addr2 City State Zip
Billy Bob 123 High Rd. Hereville Florida 12345
Sally Smith 321 Low Rd. Nowhere Alaska 54321
Jimmy Dean 222 Middle Rd. Whoville Ohio 55555
If I was prompted for a # and typed in "3", then the following result would be required:
Name Addr1 Addr2 City State Zip
Billy Bob 123 High Rd. Hereville Florida 12345
Billy Bob 123 High Rd. Hereville Florida 12345
Billy Bob 123 High Rd. Hereville Florida 12345
Sally Smith 321 Low Rd. Nowhere Alaska 54321
Sally Smith 321 Low Rd. Nowhere Alaska 54321
Sally Smith 321 Low Rd. Nowhere Alaska 54321
Jimmy Dean 222 Middle Rd. Whoville Ohio 55555
Jimmy Dean 222 Middle Rd. Whoville Ohio 55555
Jimmy Dean 222 Middle Rd. Whoville Ohio 55555
Assume that there the possibility for more columns to be added over time as well, so it should copy the whole row rather than a fixed range.
I would be much indebted if someone could help!
Many thanks, Alan
I have a regularly increasing DB of address information in Excel with several hundred entries with row 1 as the header row. Depending on the demand, we have to create mail labels in various quantities per address, consecutively. I foresee a macro that when kicked off will prompt the user to enter in the number of labels for each row and then duplicate each unique row that number of times (except the header row, of course).
It would be best if it creates the duplicate row list on another sheet. There is only 1 sheet in the workbook as it stands.
For example:
Name Addr1 Addr2 City State Zip
Billy Bob 123 High Rd. Hereville Florida 12345
Sally Smith 321 Low Rd. Nowhere Alaska 54321
Jimmy Dean 222 Middle Rd. Whoville Ohio 55555
If I was prompted for a # and typed in "3", then the following result would be required:
Name Addr1 Addr2 City State Zip
Billy Bob 123 High Rd. Hereville Florida 12345
Billy Bob 123 High Rd. Hereville Florida 12345
Billy Bob 123 High Rd. Hereville Florida 12345
Sally Smith 321 Low Rd. Nowhere Alaska 54321
Sally Smith 321 Low Rd. Nowhere Alaska 54321
Sally Smith 321 Low Rd. Nowhere Alaska 54321
Jimmy Dean 222 Middle Rd. Whoville Ohio 55555
Jimmy Dean 222 Middle Rd. Whoville Ohio 55555
Jimmy Dean 222 Middle Rd. Whoville Ohio 55555
Assume that there the possibility for more columns to be added over time as well, so it should copy the whole row rather than a fixed range.
I would be much indebted if someone could help!
Many thanks, Alan