Creating Your Own Mail Merge Documents

This section simply covers how to "roll your own" if the AutoPilot approach doesn't suit your needs. (For more information, see Chapter 35, Creating and Modifying Data Sources , on page 871.)

Note

If you have problems completing any of these procedures, see How to Make It Work.


Note

To switch data sources later, see Switching to a Different Data Source for a Mail Merge Document on page 376.


How to Make It Work

Often, the document doesn't want to accept the fields you're dragging into itwhen your mouse moves over the document, the big black "Ghostbusters" symbol will appear and the field won't appear.

To correct this, try one of the following before you drag in the fields: if one doesn't work, the other will.

Approach A: Toggle the editability of the document

Follow these steps.

  1. Save the document at least once. If the document hasn't been saved, the document will be untitled and the Edit File icon on the function bar at the top will be dimmed, as shown at right.

    graphics/10inf05.jpg

  2. If the document has been saved, the Edit File icon will look like this, at right.

    graphics/10inf06.jpg

  3. Then click the Edit File icon. The icon will appear flat now instead of recessed, as shown at right.

    graphics/10inf07.jpg

  4. Then click it again to make the file editable again; the icon will be recessed again, as shown at right.

    graphics/10inf08.jpg

Approach B: Don't save the document

Drag the fields into a new empty document and don't save it until all the fields are in.

Approach C: Save the document first

This is the opposite of Approach B, yes. Try it anyway; if A and B haven't work, C might.

Dragging Data Source Fields Into a Document

Dragging fields in is a really slick way to get the data you want. Just make sure you follow the guidelines in How to Make It Work or it won't.

  1. Open a document.

  2. Choose View > Data Sources.

  3. Expand the data source viewing list at the left and navigate to the data source and table you want to get data from, as shown in Figure 10-27.

    Figure 10-27. Viewing data source fields

    graphics/10fig27.jpg

  4. Select the first field you want to appear in the document, such as the first name , by clicking on the heading such as First and dragging the heading into the document (see Figure 10-28).

    Figure 10-28. Dragging database fields into a document for mail merge

    graphics/10fig28.jpg

  5. The field will appear in the document as shown in Figure 10-29.

    Figure 10-29. Result of dragging a data source field into your own document

    graphics/10fig29.jpg

  6. Drag in any additional fields. Make sure you put the correct spacing in between the fields, and the correct line breaks. Otherwise you'll end up with something like this in your document:

    ElaineNelson666AspenLaneBerthoudCO80022

To print what you've created, see Printing on page 399.

Inserting Data Source Information as Text Instead of as Fields Linked to the Data Source

Let's say you just want to send a friend your address book, and it's in a data source. Yo don't care if the document is linked back to the data source; you just want to send out the information. Here's how to do it.

Inserting Data Sources as Plain Text

If all you want to do is get some information from data sources into a regular ol' Writer document, here's how.

  1. Open a new Writer document.

    graphics/10fig30a.gif

  2. Choose View > Data Sources.

  3. Expand the data source viewing list at the left and navigate to the data source and table you want to get data from, as shown in Figure 10-30.

    Figure 10-30. Viewing data source fields

    graphics/10fig30.jpg

  4. Click the empty rectangle at the upper left corner as shown in Figure 10-31.

    Figure 10-31. Selecting the data in the data source viewer to drag to the document

    graphics/10fig31.jpg

  5. Drag the table into the document. The window in Figure 10-32 will appear. Make the appropriate entries and click OK.

    Figure 10-32. Choosing how to format data source data in a Writer document

    graphics/10fig32.jpg

To print what you've created, just choose File > Print and print normally.

Inserting Data Sources as Plain Text in a Table
  1. Open a new Writer document.

  2. Choose View > Data Sources.

  3. Expand the data source viewing list at the left and navigate to the data source and table you want to get data from.

  4. Click the empty rectangle at the upper left corner and drag it into the document.

  5. The window in Figure 10-33 will appear. Make the appropriate entries and click OK.

    Figure 10-33. Specifying the structure of the table to insert

    graphics/10fig33.jpg

Figure 10-34 shows an inserted table; the AutoFormat button was used to apply the blue table format theme.

Figure 10-34. A field created from inserting a data source

graphics/10fig34.jpg

You can print it directly without an extra step since the data is plain text, not fields.

Figure 10-35. Finishing a document containing data source data

graphics/10fig35.jpg

To print, just choose File > Print and print normally.



OpenOffice. org 1.0 Resource Kit
OpenOffice.Org 1.0 Resource Kit
ISBN: 0131407457
EAN: 2147483647
Year: 2005
Pages: 407

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net