emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Michael Welle <mwe012008@gmx.net>
To: emacs-orgmode@gnu.org
Subject: Re: two basic elisp questions
Date: Fri, 22 Jul 2016 19:27:39 +0200	[thread overview]
Message-ID: <cl1a6dxoub.ln2@news.c0t0d0s0.de> (raw)
In-Reply-To: CAN_Dec87yipA6ps_pb9mqAFSx_a2yyomEExdf6O=hPwxoUxAWA@mail.gmail.com

Hello,

Matt Price <moptop99@gmail.com> writes:

> (1) can I interactively call an e lisp function like "org-set-property" and
> provide a single argument to it even if it expects 2, e.g.:
> (call-interactively 'org-set-protertyt (vector "GRADE" ))? (I don't seem to
> be able to pass ANY arguments via call-interactively so maybe I
> misunderstand something fundamental).
right, call-interactively uses the interactive form of the called
function to figure out the parameters and their values. Maybe you are
looking for something like this:


(defun set-foo-value (value)
  (interactive
   (list (read-string "prop value: " nil nil "<empty>")))
  (org-set-property "foo" value))

(call-interactively 'set-foo-value)

Regards
hmw

      parent reply	other threads:[~2016-07-22 17:30 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-22 15:38 two basic elisp questions Matt Price
2016-07-22 16:13 ` Matt Price
2016-07-22 17:54   ` Michael Welle
2016-07-23  2:27     ` Matt Price
2016-07-23  5:24       ` Michael Welle
2016-07-29 14:15         ` Matt Price
2016-07-22 17:27 ` Michael Welle [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=cl1a6dxoub.ln2@news.c0t0d0s0.de \
    --to=mwe012008@gmx.net \
    --cc=emacs-orgmode@gnu.org \
    /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).