From: Max Mikhanosha <max@openchat.com>
To: Sebastien Vauban <wxhgmqzgwmuf@spammotel.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: [Sticky Agenda] How to create Agenda Buffers in functions
Date: Thu, 19 Apr 2012 21:39:04 -0400 [thread overview]
Message-ID: <87bomnnpvr.wl%max@openchat.com> (raw)
In-Reply-To: <80obqn79yz.fsf@somewhere.org>
At Thu, 19 Apr 2012 22:17:08 +0200,
Sebastien Vauban wrote:
> I tried the updated version of Sven:
>
> #+begin_src emacs-lisp
> (defun my-gtd-frame ()
> (interactive)
> (save-excursion)
> (make-frame '(
> (name . "gtd")
> (active-alpha . 0.75)
> (inactive-alpha . 0.8)
> (top . 20)
> (left . 20)
> (width . 80)
> (height . 40)))
> (select-frame-by-name "gtd")
> (org-agenda-goto-today)
> (delete-other-windows)
> (split-window-horizontally)
> (other-window 1)
> (catch 'exit
> (org-batch-agenda "work")))
> #+end_src
>
> But I get the following error:
>
> --8<---------------cut here---------------start------------->8---
> Debugger entered--Lisp error: (error "Not allowed in nil-type agenda buffers")
> signal(error ("Not allowed in nil-type agenda buffers"))
> error("Not allowed in %s-type agenda buffers" nil)
> (if error (error "Not allowed in %s-type agenda buffers" org-agenda-type) nil)
> (if (memq org-agenda-type types) t (if error (error "Not allowed in %s-type agenda buffers" org-agenda-type) nil))
> org-agenda-check-type(t timeline agenda)
> org-agenda-goto-today()
> my-gtd-frame()
> call-interactively(my-gtd-frame)
> ...
> Am I missing something?
>
The call to (org-agenda-goto-today) is before it created the agenda, I
think it should be inside the catch, after the (org-batch-agenda) call.
Regards,
Max
prev parent reply other threads:[~2012-04-20 1:39 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-04-03 17:10 [Sticky Agenda] How to create Agenda Buffers in functions Sven Bretfeld
2012-04-04 0:23 ` Max Mikhanosha
2012-04-04 5:30 ` Sven Bretfeld
2012-04-19 20:17 ` Sebastien Vauban
2012-04-20 1:39 ` Max Mikhanosha [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87bomnnpvr.wl%max@openchat.com \
--to=max@openchat.com \
--cc=emacs-orgmode@gnu.org \
--cc=wxhgmqzgwmuf@spammotel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).