From: Drew Adams <drew.adams@oracle.com>
To: Thorsten Jolitz <tjolitz@gmail.com>, help-gnu-emacs@gnu.org
Subject: RE: Possible to access previous arg in `interactice' call?
Date: Sat, 2 Aug 2014 09:29:51 -0700 (PDT) [thread overview]
Message-ID: <61fe3fcb-0762-4f7a-910a-d80b67ab072b@default> (raw)
In-Reply-To: <8738dff5os.fsf@gmail.com>
> (interactive (list (read-number "Num1: ")
> (+ (read-number "Num2: ") num1)))
>
> -> list: Symbol's value as variable is void: num1
Bind the value returned by the first `read-number' to a local
variable, and use that.
(interactive
(let ((n1 (read-number "Num1: ")))
(list n1 (+ (read-number "Num2: ") n1))))
next prev parent reply other threads:[~2014-08-02 16:29 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-02 12:15 Possible to access previous arg in `interactice' call? Thorsten Jolitz
2014-08-02 16:29 ` Drew Adams [this message]
2014-08-02 17:36 ` Thorsten Jolitz
[not found] ` <mailman.6474.1407001032.1147.help-gnu-emacs@gnu.org>
2014-08-02 20:57 ` Pascal J. Bourguignon
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.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=61fe3fcb-0762-4f7a-910a-d80b67ab072b@default \
--to=drew.adams@oracle.com \
--cc=help-gnu-emacs@gnu.org \
--cc=tjolitz@gmail.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.
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).