Everything done below highlighted row

tropics123

Board Regular
Joined
May 11, 2016
Messages
85
Hi! Any help on this would be greatly appreciated.

For example, row 89 is highlighted yellow but it can vary depending on the different data received daily. Everything above the highlighted yellow row are data and below the yellow highlighted row are all empty cells. Above the yellow highlighted row are many columns filled with data, and a lot of the columns have repeated headers. For example, there will be multiple columns with the header names "Type" and "Credit". I need some help with #2 & #3 below :smile: I greatly appreciate your help.

1) Above the yellow highlighted row: copy all data from columns A-L and paste it in the first empty cell in column A below the highlighted row. This one I can do the macro for.

2) If header name is "Type" (and may appear in multiple columns), put in word "Finance" in the same column directly below the yellow highlighted row and go all the down to match with the number of rows in column A (the word "Finance" can only start below the yellow highlighted row)

3) Copy all amounts in columns with header "Credit" and change the amounts to a positive number. The header "Credit" might be in multiple columns and need to find them all, and paste it directly in its respective columns below the yellow highlighted row.
 
Last edited:
Hi Rick,

I tried your codes and it's not doing anything :( Sorry...I did leave out some pertinent information. I made some updates to the example table above. Row 1 contains the header. Everything above row 5 was already existing. The blue font was copied directly down below from above rows (no changes). The red font is what I'm hoping the VBA could do.

I wanted the VBA code to look in the header row for the word "Cont Type" (<- made change to that header since I just realized it's actually two words rather than one) and put the word "Finance" below the yellow highlighted row 5 and goes all the way down to match the number of rows in column A.

[TABLE="class: cms_table_grid, width: 600, align: center"]
<tbody>[TR]
[/TR]
[TR]
[TD][/TD]
[TD]columns A -->[/TD]
[TD]L[/TD]
[TD]M[/TD]
[TD]N[/TD]
[TD]O[/TD]
[TD]P[/TD]
[TD]Q[/TD]
[TD]R[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Name[/TD]
[TD]Header[/TD]
[TD]Cont Type[/TD]
[TD]Credit[/TD]
[TD]Cont Type[/TD]
[TD]Credit[/TD]
[TD]Cont Type[/TD]
[TD]Credit[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]Bob[/TD]
[TD]info[/TD]
[TD]1[/TD]
[TD]-800[/TD]
[TD]4[/TD]
[TD]-420[/TD]
[TD]1[/TD]
[TD]-486[/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]Susan[/TD]
[TD]info[/TD]
[TD]2[/TD]
[TD]-250[/TD]
[TD]1[/TD]
[TD]-510[/TD]
[TD]5[/TD]
[TD]-281[/TD]
[/TR]
[TR]
[TD]4[/TD]
[TD]Mike[/TD]
[TD]info[/TD]
[TD]5[/TD]
[TD]-310[/TD]
[TD]1[/TD]
[TD]-140[/TD]
[TD]2[/TD]
[TD]-334[/TD]
[/TR]
[TR]
[TD]5[/TD]
[TD]FF (yellow highlight line starts here)[/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]6[/TD]
[TD]Bob[/TD]
[TD]info[/TD]
[TD]Finance[/TD]
[TD]800[/TD]
[TD]Finance[/TD]
[TD]420[/TD]
[TD]Finance[/TD]
[TD]486[/TD]
[/TR]
[TR]
[TD]7[/TD]
[TD]Susan[/TD]
[TD]info[/TD]
[TD]Finance[/TD]
[TD]250[/TD]
[TD]Finance[/TD]
[TD]510[/TD]
[TD]Finance[/TD]
[TD]281[/TD]
[/TR]
[TR]
[TD]8[/TD]
[TD]Mike[/TD]
[TD]info[/TD]
[TD]Finance[/TD]
[TD]310[/TD]
[TD]Finance[/TD]
[TD]140[/TD]
[TD]Finance[/TD]
[TD]334[/TD]
[/TR]
[TR]
[TD]9[/TD]
[TD]FF[/TD]
[TD][/TD]
[TD]Finance[/TD]
[TD][/TD]
[TD]Finance[/TD]
[TD][/TD]
[TD]Finance

[/TD]
[/TR]
</tbody>[/TABLE]
 
Upvote 0

Excel Facts

How to change case of text in Excel?
Use =UPPER() for upper case, =LOWER() for lower case, and =PROPER() for proper case. PROPER won't capitalize second c in Mccartney

Forum statistics

Threads
1,223,893
Messages
6,175,240
Members
452,621
Latest member
Laura_PinksBTHFT

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