[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: send agenda-weekly-view via email html formated
From: |
Ihor Radchenko |
Subject: |
Re: send agenda-weekly-view via email html formated |
Date: |
Sun, 31 Oct 2021 16:47:43 +0800 |
Ihor Radchenko <yantar92@gmail.com> writes:
> Uwe Brauer <oub@mat.ucm.es> writes:
>
>> I know I can save my weekly agenda view as a HTML file and then send it as
>> as attachment.
Sorry, I misread your first message. Attaching and sending is easy:
(defun org-agenda-email ()
"Email agenda in current buffer as attachment."
(interactive)
(let ((to (read-string "Send to: "))
(subject (read-string "Subject: ")))
(unless (derived-mode-p 'org-agenda-mode) (user-error "Should start from
agenda view."))
(org-agenda-write (file-name-concat (temporary-file-directory)
"agenda.html") nil nil (current-buffer))
(compose-mail to subject)
(save-excursion
(goto-char (point-max))
(mml-attach-file (file-name-concat (temporary-file-directory)
"agenda.html")))))
Best,
Ihor