From mboxrd@z Thu Jan 1 00:00:00 1970 From: lecodesportif@eml.cc Subject: Re: Using properties for diary-anniversaries Date: Mon, 24 Jan 2011 00:27:54 -0800 Message-ID: <1295857674.26398.1416871253@webmail.messagingengine.com> References: <1295793360.20637.1416756473@webmail.messagingengine.com> <7298.1295831795@gamaville.dokosmarshall.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from [140.186.70.92] (port=33088 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PhHmH-0003C8-FJ for emacs-orgmode@gnu.org; Mon, 24 Jan 2011 03:27:58 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PhHmG-00012o-6F for emacs-orgmode@gnu.org; Mon, 24 Jan 2011 03:27:57 -0500 Received: from new1.smtp.messagingengine.com ([66.111.4.221]:33716) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PhHmG-00012k-1D for emacs-orgmode@gnu.org; Mon, 24 Jan 2011 03:27:56 -0500 In-Reply-To: <7298.1295831795@gamaville.dokosmarshall.org> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Nick Dokos Cc: emacs-orgmode@gnu.org On Sun, 23 Jan 2011 20:16 -0500, "Nick Dokos" wrote: > lecodesportif@eml.cc wrote: > > > I have an anniversary list in Org Mode where entries have this format: > > > > * John > > :PROPERTIES: > > :Name: John > > :Birthday: 5 4 1900 > > :END: > > > > I would like to add the "Birthday" and "Name" properties to Org Agenda > > automatically. What I have so far is: > > > > %%(apply 'diary-anniversary (read (org-entry-get nil "Birthday"))) John > > > > When I enter this line right after the properties, the anniversary is > > added at the correct date in the agenda. But I still have to enter the > > name manually. > > > > Try something like this: > > %%(apply 'diary-anniversary (mapcar 'string-to-number (split-string > (org-entry-get nil "Birthday")))) John is %d years old The %d was already working with my above code and the entry was displayed at the correct date. What I am looking for is a way to get the value of the name property ("John") automatically. That way I wouldn't have to insert all names manually in the %%(apply... line following the properties. -- http://www.fastmail.fm - Accessible with your email software or over the web