Multiple Row Headers and copy and pasting its corresponding data into a master sheet

VBA learner ITG

Active Member
Joined
Apr 18, 2017
Messages
272
Office Version
  1. 365
Platform
  1. Windows
  2. MacOS
Good afternoon,

Thank you for reading my post.

I have imported over 1000 documents into one master document by a VBA code of copy and paste to create a database.

The database has rows of data each with their own headers and and metadata below it.


Example:

[TABLE="class: grid, width: 500, align: center"]
<tbody>[TR]
[TD]Header 1[/TD]
[TD]Header 2[/TD]
[TD]Header 3[/TD]
[TD][/TD]
[TD]Header 4[/TD]
[/TR]
[TR]
[TD]metadata[/TD]
[TD]metadata[/TD]
[TD][/TD]
[TD][/TD]
[TD]Meta Data[/TD]
[/TR]
[TR]
[TD]empty row[/TD]
[TD]empty row[/TD]
[TD]empty row[/TD]
[TD]empty row[/TD]
[TD]empty row[/TD]
[/TR]
[TR]
[TD]Header 2[/TD]
[TD]Header 3[/TD]
[TD]Header 1[/TD]
[TD][/TD]
[TD]Header 1[/TD]
[/TR]
[TR]
[TD]metadata[/TD]
[TD]metadata[/TD]
[TD]Metadata[/TD]
[TD][/TD]
[TD]metadata[/TD]
[/TR]
[TR]
[TD]metadata[/TD]
[TD]metadata[/TD]
[TD]metadata[/TD]
[TD][/TD]
[TD]Metadata[/TD]
[/TR]
</tbody>[/TABLE]


I was wondering is there a way to cycle through over 16000 lines of data in the database to find header 1 and all its data that is below it until it stops at a empty row like an index and match.
 

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.

Forum statistics

Threads
1,225,743
Messages
6,186,773
Members
453,370
Latest member
juliewar

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