[hblug] Mail Merge Aficionados?

Perry Spiller p.spiller at xtra.co.nz
Sun Feb 3 15:06:02 NZDT 2008


----------------Earlier, Michael commented--------------------
>Base will happily use your spreadsheets as a database source.
>
>Mailmerge is a tricky beast in OO.o but the manual to the rescue:
>http://documentation.openoffice.org/manuals/oooauthors2/

Hmmm, not at all easy, it seems.

The data source seems to be the easy matter. The mail merge
document is the killer. OO seems very restricted: letters,
labels & envelopes.

Windoze at least offers a catalogue option (which is what
I want) but the conditional instructions are, aahhhhh,
challenging.

It seems to be able to test records – maybe, but unable to test
fields within records. The test-record option only (seems to)
allow an "equal to" test – not "contains." I can't make it
work, which has me wondering if the "equal to" test will
return a false, if there are other characters in the field,
including spaces. (I doubt that, though)

In 'long-hand,' here's a sample of what I'm trying to achieve.
Bracketed words signify <field name>

IF <keyword> contains (the word) 'redundant' [true response]
skip to next record (and repeat that test [for every record!])

Should that above conditional test return a [false response]
then, extract the data from the record, thus:

IF <name1> contains data, insert that data in bold, followed
by a tab, ELSE IF <name1> contains no data, skip to next
field.

IF <name2> contains data, insert that data, followed by a
comma and a space, ELSE IF <name2> contains no data,
skip to next field.

  . . . . . . . . .

If <home_tel> contains data, insert the text string "Home
Tel:" in bold, then the field data, followed by a comma and a
space, ELSE IF <home_tel> contains no data, skip to next
field.

On and on and on . . . .  till the end-of-record, [where two
carriage returns are inserted] then move to the next record
until end of file. (Ye olde WHILE WEND instruction)


Perry
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.linux.net.nz/pipermail/hblug/attachments/20080203/922df0fe/attachment.htm


More information about the HBLUG mailing list