[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
A way for interactive to modify a let-bound variable?
From: |
Kaushal Modi |
Subject: |
A way for interactive to modify a let-bound variable? |
Date: |
Fri, 12 Feb 2016 11:41:07 -0500 |
Hi,
The below snippet will of course not work but I would like to achive
something like that:
(defun my-dummy-fn ()
(let (msg)
(interactive (progn
(if (use-region-p)
(setq msg "Region")
(setq msg "No region"))
nil))
(message msg)))
This is a very simplified example. But I need to change a let-bound
variable in the interactive form based on some condition and then use that
variable in the defun body.
Is that possible?
--
Kaushal Modi
- A way for interactive to modify a let-bound variable?,
Kaushal Modi <=
- RE: A way for interactive to modify a let-bound variable?, Drew Adams, 2016/02/12
- Re: A way for interactive to modify a let-bound variable?, Michael Heerdegen, 2016/02/12
- Re: A way for interactive to modify a let-bound variable?, Kaushal Modi, 2016/02/12
- Re: A way for interactive to modify a let-bound variable?, Michael Heerdegen, 2016/02/12
- Re: A way for interactive to modify a let-bound variable?, Kaushal Modi, 2016/02/12
- Re: A way for interactive to modify a let-bound variable?, Michael Heerdegen, 2016/02/12
- Re: A way for interactive to modify a let-bound variable?, Kaushal Modi, 2016/02/12
- Re: A way for interactive to modify a let-bound variable?, Marcin Borkowski, 2016/02/12