help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: macro with argument


From: David Kastrup
Subject: Re: macro with argument
Date: 20 Oct 2003 13:57:29 +0200
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50

Joerg Schuster <address@hidden> writes:

> Hello,
> 
> how can I write "macros with arguments"?
> 
> Example: 
> 
> [Me:]    M-x my_macro
> [Emacs:] your argument:
> [Me:]    foo
> 
> Then emacs should print e.g.
> 
> bla foo blo

(defun my_macro (string) (interactive "syour argument: ") (message
"bla %s blo" string))

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum


reply via email to

[Prev in Thread] Current Thread [Next in Thread]