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

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

Re: Inserting date into document


From: Kai Großjohann
Subject: Re: Inserting date into document
Date: Mon, 25 Jun 2001 14:48:09 +0200
User-agent: Gnus/5.090004 (Oort Gnus v0.04) Emacs/21.0.104

On Mon, 25 Jun 2001, lordemsworthx@yahoo.com wrote:

> Is it possible to insert the current date into the current buffer
> (even it its not the diary)? If yes, then how can one manipulate its
> format?

(defun le-insert-date ()
  "Insert the current date into the current buffer."
  (interactive)
  (insert (format-time-string "%Y-%m-%d")))

See the documentation of format-time-string to learn how to customize
the format.

kai
-- 
~/.signature: No such file or directory



reply via email to

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