Importing marked-up text into tables?

  • Thread starter Thread starter John Cutler
  • Start date Start date
J

John Cutler

Hi, all ---

This post may belong on a different newsgroup, but I'll
try it here for starters....

The reports I write are composed of a series of chapters,
each chapter containing 5 pages, each page with 3
identical tables. There is no other text (except headers
and footers) on a page.

Cells in a table are of varying size and content, but each
cell has a title line (such as "Date:") -- either followed
by data on the same line, or data on the next line down.
One cell in each table contains a photo.

To make this all clearer, SAMPLES of the page showing
tables (including data or not) are available on request...

All the data that go in these tables are currently being
typed in by hand, but data for most of the cells
(including the file name of the photo) aready exist in a
database. Only one cell -- the narrative describing the
photo -- does not have a corresponding database entry;
this would continue to be typed into each table by hand.

I used to work with typesetting programs (e.g., Ventura
Publisher) that could import "marked-up" text files. The
data (for calendars) were kept in a database; I wrote the
software to process these database entries into "marked-
up" text files, which were then "imported" into the
typesetting program.

The actual text (data) that were visible as content in the
calendar table contained imbedded code sequences that
controlled the placement of the text (which day of the
month and where inside that cell), the font and point
size, whether bold or italic, justification, and so on.
The "mark-up" codes even drew the lines (line weight,
position, etc.) to make the table cells (the 7x6 grid of
cells for each month's calendar page).

QUESTION: is it possible to import "marked-up text" into
a table, or series of tables, in a Word 97 document?

Being able to automatically export the database content to
the correct table cells would speed up the project and
save a lot of typing errors!

Thanks

John Cutler
Mapping Director / Ozark Regional Land Trust
(e-mail address removed)
 
Hi, John,

Word can handle the kind of job you describe.

Treat the database as a mailmerge source. This isn't my area of expertise,
so someone else will have to guide you in setting up the merge fields, but
this is the way to start.

The mailmerge output will need post-processing to convert the markup to
formatting. Word is not at all like Ventura in this respect; the markup
can't be "automagically" interpreted during the import phase. You'll need a
macro that does multiple find/replace operations, probably using wildcard
searching (see http://word.mvps.org/FAQs/General/UsingWildcards.htm). If you
want to post a small sample of markup, we can suggest how to write the
replacements.

Don't try to have the markup draw table lines. Instead, the template used
for the mailmerge should already contain the tables with the proper borders,
and the merge fields should be in the table's cells along with any text
that's constant from one document to the next (e.g., your "Date:" caption).
 
Jay --

Thanks for the response. I've been too busy until today to
come back to this project....

I've set up and run mailmerge with other database/word
processors, but have not tried it in Word (I'll need to do
a little research!) Nor have I written any find/replace
macros for Word (I'm a computer programmer, which should
help...).

The database I'm using is not Access, though it is ODBC
compliant and so should be usable for this. I could
probably figure out some way to port my data to an Access
file and thence on to Word.

Where do I go from here? Can you aim me at the "someone
else [who] will have to guide [me] in setting up the merge
fields"?

How do I
...post a small sample of markup, [so] we can suggest how
to write the replacements. ?? Are you asking for one of
my document pages that contains the tables? Perhaps one
with data and headings, and one without data?

John Cutler
(e-mail address removed)

-----Original Message-----
Hi, John,

Word can handle the kind of job you describe.

Treat the database as a mailmerge source. This isn't my area of expertise,
so someone else will have to guide you in setting up the merge fields, but
this is the way to start.

The mailmerge output will need post-processing to convert the markup to
formatting. Word is not at all like Ventura in this respect; the markup
can't be "automagically" interpreted during the import phase. You'll need a
macro that does multiple find/replace operations, probably using wildcard
searching (see
http://word.mvps.org/FAQs/General/UsingWildcards.htm). If
you
 
Back
Top