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 :) 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.

columns A -->LMNOPQR
1NameHeaderCont TypeCreditCont TypeCreditCont TypeCredit
2Bobinfo1-8004-4201-486
3Susaninfo2-2501-5105-281
4Mikeinfo5-3101-1402-334
5FF (yellow highlight line starts here)
6BobinfoFinance800Finance420Finance486
7SusaninfoFinance250Finance510Finance281
8MikeinfoFinance310Finance140Finance334
9FFFinanceFinanceFinance


<tbody>
</tbody>
 
Upvote 0

Excel Facts

Control Word Wrap
Press Alt+Enter to move to a new row in a cell. Lets you control where the words wrap.

Forum statistics

Threads
1,214,528
Messages
6,120,065
Members
448,942
Latest member
sharmarick

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