Macro or VBA

  • Thread starter Thread starter Don
  • Start date Start date
D

Don

I have about 100 RTF/6.0 files created with WordPad, with another 100 or
more for completion.
These files are stored under multiple folders and subfolders. With all
the files being under a master folder.At the very most, four folders deep
from the root folder.

Text is mixed within the files along with tabular data.
The tabular data "always begins and ends a paragraph.
The tabs for the tabular data, have been set the same on each RTF.

Any ideas on how extract the tabular data from all the files
simultaneously and into a single new file?

Ex:

paragraph of text

paragraph of tabular data

paragraph of text

paragraph of tabular data

In addition some of the files just contain the tabular data.

Thanks in advance.
 
A macro (all macros are VBA) would do it, but it's a fair challenge if
you're a VBA novice.

There are three tasks: iterating the folder structure to get to each source
file, extracting the data from each, and doing something with the data. The
first is easy enough -- you'll find sample macros around that work their way
through folders of files.

Pulling data out of regular tables is also easy enough: you iterate the
cells. You haven't said anything about what you want to do with the
extracted data.

You might consider doing all this in Excel -- the file reading part is the
same; but Excel will automatically distribute the tabulated material across
multiple cells. So your task might be as easy as identifying rows to delete.
And you end up with your data in a spreadsheet, which is often no bad format
for tabular data.
 
A macro (all macros are VBA) would do it, but it's a fair challenge if
you're a VBA novice.

There are three tasks: iterating the folder structure to get to each
source file, extracting the data from each, and doing something with
the data. The first is easy enough -- you'll find sample macros around
that work their way through folders of files.

Pulling data out of regular tables is also easy enough: you iterate
the cells. You haven't said anything about what you want to do with
the extracted data.

You might consider doing all this in Excel -- the file reading part is
the same; but Excel will automatically distribute the tabulated
material across multiple cells. So your task might be as easy as
identifying rows to delete. And you end up with your data in a
spreadsheet, which is often no bad format for tabular data.

Many thanks Jezebel
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top