next up previous contents
Next: Input Filters Up: BBDB Filters & Processors Previous: Setup

Subsections

  
Output Filters

``Output filters'' are used to export BBDB information into formats used by other systems.

In general, an output filter uses the contents of your *BBDB* buffer as input. Note that output filters do not use BBDB files (typically ` /.bbdb') directly.

An output filter is invoked by executing its associated lisp function. The name of the function is conventionally named bbdb-output-<system> (e.g., M-x bbdb-output-hp200lx).

The result of running an output filter is to create a new buffer that contains the *BBDB* information appropriately transformed into a format suitable for use by the target system. The new buffer is given a file name that you specify.

Microsoft Schedule+ and Windows CE Contacts

Microsoft Schedule+ and Windows CE 1.0

This output filter package has only been tested with the Microsoft Schedule+ version 7.0a software and Windows CE Version 1.0. The software is in file bbdb-schdplus.el.

1.
Invoke M-x bbdb to populate the *BBDB* buffer with the contents you wish to export.

2.
Invoke M-x bbdb-output-schdplus to create an ASCII .CSV (Comma Separated Values) BBDB export file.

3.
Start Microsoft Schedule+ program. Use the File->Import->Text... menu item to import the exported BBDB entries into Schdeule+. Follow the screens and select ``contacts'' format. The text import wizard may ask you to specify the mapping between the fields in the BBDB export file and those used by Schedule+. Simply specify fields of the same name. (e.g., ``Business City'' maps to ``Businesss City'').

4.
To use this exported information with Windows CE, you must down download it to your HPC using the HPC Explorer application. On the host computer start the HPC Explorer application. Use Tools->Synchronize now to initiate the transfer.

If the menu item is grayed out you should use bring up the Tools->Synchronization Manager... dialog and check the box for ``Enable Appointment, Contact and Task Synchronization''. Leave unchecked the box for ``Automatically synchronize upon connecting''.

Microsoft Schedule+ and Windows CE 2.0

This output filter package has been tested with Microsoft Schedule+ version 7.0a (this program is part of Microsoft Outlook) and Windows CE version 2.0. The software is in file bbdb-schdplus.el. Here are the steps to import the bbdb list into the Windows CE device:

1.
Invoke M-x bbdb to populate the *BBDB* buffer with the contents you wish to export.
2.
Invoke M-x bbdb-output-schdplus to create an ASCII .CSV (Comma Separated Values) BBDB export file. It will automatically ask you to save bbdb-schdplus.csv file. Just accept the default file name but you may want to specify your own location of the file.
3.
In your Windows machine, open the Microsoft Outlook program.
4.
Click on File menu and then click on Import & Export.
5.
Click om Import from Schedule+ or another program or file and then click Next.
6.
Choose the Comma Separated Values (DOS) and then click Next.
7.
Locate the file to be imported (the bbdb-schdplus.csv) and then click Next.
8.
Select the Contacts as the destination folder and then click Next.

Netscape Address Book (Version 4.x) and Windows NT

This output filter package has only been tested with the Netscape Communicator 4.72 and Windows NT OS. The software is in file bbdb-nsmail.el.

1.
Invoke M-x bbdb to populate the *BBDB* buffer with the contents you wish to export.
2.
Invoke M-x bbdb-output-nsmail to create an HTML file.
3.
You will be prompted to save the HYML file to a file. The default is ~/.netscape/address-book.bbdb.html. To accept the default, just press enter.
4.
After you created the HTML file, open the Netscape Communicator on your Windows NT machine and then click on the ``Communicator -> Address Book''.
5.
You suppose to be in the Address Book window. In the Address Book window, click on File -> New Address Book. You'll be prompted to create a new Address Book name. Type in the address book name that you want to import to Netscape address book.
6.
Under the Directory column, you'll see the Address Book that you just created. Click on that new address book name. Right now, it should be empty.
7.
Click on File -> Import -> Communicator Address Book, and then click Next. Under ``Files of type'', select the HTML Files and then locate the HTML files that you created from the BBDB (i.e. address-book.bbdb.html), adn then click Open. It shuld automatically put the imported HTML files in your address book.

Netscape Address Book (Version 6) and Windows NT

This output filter package has only been tested with the Netscape Communicator 6 and Windows NT OS. The software is in file bbdb-netscape6.el.

1.
Invoke M-x bbdb to populate the *BBDB* buffer with the contents you wish to export.
2.
Invoke M-x bbdb-output-netscape6 to create CSV file.
3.
You will be prompted to save the CSV file to a file. The default is ~/bbdb-netscape6.csv. To accept the default, just press enter. This name will be the name of your Netscape 6 Address Book.
4.
After you created the CSV file, open the Netscap 6 on your Windows NT machine and then click on the ``Task -> Address Book''.
5.
You suppose to be in the Address Book window. In the Address Book window, click on File -> Import. The type of materila to import: Address Book. Next.
6.
Click on Text, then Next
7.
Select the CSV file that you just created, then click Next. Then just click OK.

Palm Pilot

The software is in file bbdb-palmpilot.el. Here are the steps to import the bbdb list into the Windows CE device:

1.
Invoke M-x bbdb to populate the *BBDB* buffer with the contents you wish to export.
2.
Invoke M-x bbdb-output-palmpilot to create an ASCII .CSV (Comma Separated Values) BBDB export file. It will automatically ask you to save bbdb-palmpilot.csv file. Just accept the default file name but you may want to specify your own location of the file.
3.
The rest of the steps will be documented later (as of 001106)

PC Eudora

BBDB information can be exported to PC Eudora in two formats-as a nickname database file and as a recipients database file.

The PC Eudora output filter is in file bbdb-eudora.el.

PC Eudora Nickname Database

1.
Invoke M-x bbdb to populate the *BBDB* buffer with the contents you wish to export.

2.
Invoke bbdb-output-eudora-nndbase to create a PC Eudora Nickname database file.

3.
Make the file accessible to PC Eudora.

PC Eudora Recipient Database

1.
Invoke M-x bbdb to populate the *BBDB* buffer with the contents you wish to export.

2.
Invoke bbdb-output-eudora-rcpdbase to create a PC Eudora recipient's database file.

3.
Make the file accessible to PC Eudora.

Lotus cc:Mail Nicknames

The Lotus cc:Mail output filter is in file bbdb-ccmail.el.

1.
Invoke M-x bbdb to populate the *BBDB* buffer with the contents you wish to export.

2.
Invoke bbdb-output-ccmail to create a cc:Mail Nicknames file.

3.
Make the file accessible to cc:Mail.

PH

The PH output filter is in file bbdb-ph.el.

1.
Invoke M-x bbdb to populate the *BBDB* buffer with the contents you wish to export.

2.
Invoke bbdb-output-ph to create a ph data file for use with the maked program.

3.
Make the file accessible to ph.

Emacs Lisp Export

The Emacs Lisp Export output filter is in file bbdb-export.el.

This output filter uses the current contents of your *BBDB* buffer to generate a new buffer (*BBDB* Export) that contains a single lisp (progn ...) expression. For example, a *BBDB* buffer containing two records would result in the following *BBDB* Export buffer:

;;; ======= Start of Exported BBDB Records =======
(progn  
  (require 'bbdb-com)
  (defun bbdb-maybe-create (name company net &optional addrs phones notes)
    "Try to add a record to BBDB if it does not already exist."
    (condition-case err
        (progn
          (bbdb-create-internal name company net addrs phones notes)
          (message "%s %s added." name (if net (concat "<" net ">") ""))
          (sleep-for 1))    
      (error (ding)
             (message "%s %s skipped. (%s)"
                      name
                      (if net (concat "<" net ">") "")
                      (car (cdr err)))
             (sleep-for 1))))

  (bbdb-maybe-create "Jill Doe--IMPORTED"
                     "CBS Corporation"
                     '("jilld@cbs.com")
                     '(
                       ["Home"
                        "368 222ND PL"
                        ""
                        ""
                        "Springfield"
                        "MA" 2117]
                       )
                     '(
                       ["Office" 617 555 9983 0]
                       ) '"Movie Mogul")
  (bbdb-maybe-create "John Doe--IMPORTED"
                     "ABC Incorporated"
                     '("jdoe@abc.com")
                     '(
                       ["Office"
                        "123 Any Street"
                        ""
                        ""
                        "Any Town"
                        "WA" (98027 7758)]
                       )
                     '(
                       ["Office" 206 555 1234 0]
                       ) '"TV Producer")
  )
;;; ======= End of Exported BBDB Records =======

This lisp expression can then be sent via email or some other text-based messaging facility to another user who can then evaluate the expression which will add the BBDB records to the recipient's BBDB database.

Only new records are added. A record with the same name or net address as one already existing in the BBDB is skipped entirely.

In the sample contents of a *BBDB* Export buffer presented, two records are being exported-one for ``John Doe'' and the other for ``Jill Doe''. Notice that their names have been appended with -IMPORTED. This string can be used to quick locate each record that is added to the database using this mechanism.

The following steps are for exporting BBDB records into Emacs Lisp:

1.
Invoke M-x bbdb to populate the *BBDB* buffer with the contents you wish to export.

2.
Invoke bbdb-export to create a *BBDB* Export buffer which contains a single (progn ...) can be evaluated to add the records to the existing BBDB database (if the records do not already exist).

3.
Use the contents of *BBDB* Export in email and other messaging systems.

The following steps are for a user wishing to import the contents of a *BBDB* Export buffer's expression into his or her own database:

1.
Evaluate the region bounded by the lines
;;; ======= Start of Exported BBDB Records =======
and
;;; ======= End of Exported BBDB Records =======.
You can use such commands as M-x eval-region or M-x eval-last-sexp.

2.
Review the newly imported entries. To see them, invoke M-x bbdb and specify -IMPORTED at the Regular Expression prompt.

3.
After reviewing the contents of the imported records, you may wish to remove the -IMPORTED that is appended to the name by bbdb-export.

HP 200LX Phone Book

This package has only been tested on HP 200LX palmtop systems. It also requires the ``HP 200LX Connectivity Pack'' for converting comma-delimited ASCII files into binary .PDB files which are read by the HP 200LX Phone Book application. Version 1.00 of the ``HP 200LX Connectivty Pack'' was used for testing.

The HP 200LX output filter is in file bbdb-hp200lx.el.

1.
Invoke M-x bbdb to populate the *BBDB* buffer with the contents you wish to export.

2.
Invoke bbdb-output-hp200lx to create an ASCII .CDF (Comma Delimited File).

3.
Using Xlate/Merge option of HP Connectivity Pack convert the .CDF file into a binary .PDB file used by the Phone Book program.

4.
Download the .PDB file to your palmtop's internal disk and ensure that the Phone Book program is set use the newly downloaded .PDB file.


next up previous contents
Next: Input Filters Up: BBDB Filters & Processors Previous: Setup