From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Belohrad Subject: Re: org-capture-templates - any way how to call function for template? Date: Wed, 21 Jan 2015 16:16:21 +0100 Message-ID: <87lhkwuptm.fsf@pcbe13433.cern.ch> References: <87oapsur79.fsf@pcbe13433.cern.ch> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:45370) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YDx1D-0006IE-Q7 for emacs-orgmode@gnu.org; Wed, 21 Jan 2015 10:16:35 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YDx17-0001r6-E7 for emacs-orgmode@gnu.org; Wed, 21 Jan 2015 10:16:31 -0500 Received: from static-212-101-19-163.adsl.solnet.ch ([212.101.19.163]:51535 helo=server.belohrad.ch) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YDx17-0001r1-6b for emacs-orgmode@gnu.org; Wed, 21 Jan 2015 10:16:25 -0500 In-Reply-To: <87oapsur79.fsf@pcbe13433.cern.ch> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: org-mode mailing list ok, i've found the magic behind: ("E" "Microsoft Exchange diary entry" entry (file+datetree (concat my-org-files "diary.org")) (function testme)) )) (defun testme () "* %? :event:\n%a\n%^T\n\nEntered on %U" ) it took me some time to find out the correct syntax .d. David Belohrad writes: > Dear All, > > i want to make a capture template, which will call a function to feed > that template. Is there any way how to do it? > > Something like this: > > ("E" "Dynamic diary entry" entry (file+datetree (concat my-org-files > "diary.org")) ) > > > I have found that one can use function for _target_, but not for actual > template. Afaik template can be only loaded from a file, right? > > thanks > .d.