tpmuser2

New Member
Joined
Oct 29, 2018
Messages
3
Below is a sample of our payment register. Our check register prints the total of the check on the first line and then the account breakdown of the checks on the lines below. I need the check number and the Check Name to show up on every line of the account breakdown. I would like to create a macro that will copy the text from columns "A" and "B" and paste it to the rows below it that correspond to that particular check. I would like for the macro to continue copying the information until there are no more checks. This example has only three checks. Sometimes our payment registers have 50 checks or $100 checks. The number can vary. Can the macro continue to run until it detects no more checks in column "A"?





ABCDE
1Check NumberCheck NameTotal Check AmountAccount SplitAmount per Account
2100Sears$500
3845$225
4760$275
5200Vons$2,500
6260$500
7375$1,400
8460$600
9300Best Buy$4000
10720$4,000

<tbody>
</tbody>

The final result should look like the table below:

ABCD
1Check #Check NameTotal CheckAccount SplitAmount per Account
2100Sears$500
3100Sears845$225
4100Sears760$275
5200Vons$2,500
6200Vons260$500
7200Vons375$1,400
8200Vons460$600
9300Best Buy$4000
10300Best Buy720$4,000

<tbody>
</tbody>


Thank you

<tbody>
</tbody>

<tbody>
</tbody>
 
Last edited by a moderator:

Excel Facts

Return population for a City
If you have a list of cities in A2:A100, use Data, Geography. Then =A2.Population and copy down.
Hi & welcome to MrExcel
How about
Code:
Sub Filldown()
   With Range("A:B")
      .SpecialCells(xlBlanks).FormulaR1C1 = "=r[-1]c"
      .Value = .Value
   End With
      
End Sub
 
Upvote 0
I received the following error message:

Run time error '1004':
Unable to get the SpecialCells property the Range class
 
Upvote 0
Check that your "Blank" cells are actually blank.
=ISBLANK(A3)
 
Upvote 0

Forum statistics

Threads
1,215,034
Messages
6,122,782
Members
449,095
Latest member
m_smith_solihull

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