Function: mh-smail-batch

mh-smail-batch is an autoloaded and byte-compiled function defined in mh-comp.el.gz.

Signature

(mh-smail-batch &optional TO SUBJECT OTHER-HEADERS &rest IGNORED)

Documentation

Compose a message with the MH mail system.

This function does not prompt the user for any header fields, and thus is suitable for use by programs that want to create a mail buffer. Users should use M-x mh-smail (mh-smail) to compose mail.

Optional arguments for setting certain fields include TO, SUBJECT, and OTHER-HEADERS. Additional arguments are IGNORED.

This function remains for Emacs 21 compatibility. New applications should use mh-user-agent-compose.

Source Code

;; Defined in /usr/src/emacs/lisp/mh-e/mh-comp.el.gz
(defvar mh-error-if-no-draft nil)       ;raise error over using old draft

;;;###autoload
(defun mh-smail-batch (&optional to subject _other-headers &rest _ignored)
  "Compose a message with the MH mail system.

This function does not prompt the user for any header fields, and
thus is suitable for use by programs that want to create a mail
buffer. Users should use \\[mh-smail] to compose mail.

Optional arguments for setting certain fields include TO,
SUBJECT, and OTHER-HEADERS. Additional arguments are IGNORED.

This function remains for Emacs 21 compatibility. New
applications should use `mh-user-agent-compose'."
  (mh-find-path)
  (let ((mh-error-if-no-draft t))
    (mh-send (or to "") "" (or subject ""))))