I would like that `bbdb-complete-name' completes also by last
names. googling the topic suggested that one could add the last name
of each entry to the AKA field. however, the following does not seem
to work:

(defun bbdb-last-name-to-aka ()
  (interactive)
  (let* ((bbdb-recs  (bbdb-records))
         rec old-aka new-aka lastname)
    (while (setq rec (car bbdb-recs))
      (setq lastname (bbdb-record-lastname rec)
            old-aka (bbdb-record-aka rec))
      (if (or (string= lastname "" )
              (member lastname old-aka)) nil
        (setq new-aka
              (cons lastname old-aka))
        (bbdb-record-set-aka
         rec new-aka))
; (bbdb-save-db t t)
      (setq bbdb-recs (cdr bbdb-recs)
            count (+ count 1)))))

thanks for a solution ...

tomy

--

><(((*>

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
bbdb-info@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bbdb-info
BBDB Home Page: http://bbdb.sourceforge.net/

Reply via email to