Marco help - fill down data based a value

Garethc01

New Member
Joined
Nov 25, 2013
Messages
5
Hi Excel Guru's :)

I'm hoping one of you can help me with a macro in Excel 2007.

I have a row of data as follows on 'sheet1' with the word 'Dog' starting in cell A1.

ABC
1DogCatBird
2123

<tbody>
</tbody>

What I am after is a macro that will on 'sheet2' list the data as shown below. I want the word to appear the number of times based on the value below it.
A
1Dog
2Cat
3Cat
4Bird
5Bird
6Bird
7Bird

<tbody>
</tbody>

Any assistance would be greatly appreciated.
Gareth
 
Hi Joe, firstly sorry for the slow reply.

I copied the code straight across into excel - very strange how it is not working for me. I have checked and put a lower case 'L' and still no luck
 
Upvote 0

Excel Facts

Waterfall charts in Excel?
Office 365 customers have access to Waterfall charts since late 2016. They were added to Excel 2019.
Hi Joe, firstly sorry for the slow reply.

I copied the code straight across into excel - very strange how it is not working for me. I have checked and put a lower case 'L' and still no luck
Does your data begin in row 1 as you show in your original post? What is the value of lC when the code fails?
 
Upvote 0

Forum statistics

Threads
1,215,001
Messages
6,122,648
Members
449,092
Latest member
peppernaut

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top