Function: orgtbl-send-table
orgtbl-send-table is an interactive and byte-compiled function defined
in org-table.el.gz.
Signature
(orgtbl-send-table &optional MAYBE)
Documentation
Send a transformed version of table at point to the receiver position.
With argument MAYBE, fail quietly if no transformation is defined for this table.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/org/org-table.el.gz
(defun orgtbl-send-table (&optional maybe)
"Send a transformed version of table at point to the receiver position.
With argument MAYBE, fail quietly if no transformation is defined
for this table."
(interactive)
(catch 'exit
(unless (org-at-table-p) (user-error "Not at a table"))
;; when non-interactive, we assume align has just happened.
(when (called-interactively-p 'any) (org-table-align))
(let ((dests (orgtbl-gather-send-defs))
(table (org-table-to-lisp))
(ntbl 0))
(unless dests
(if maybe (throw 'exit nil)
(user-error "Don't know how to transform this table")))
(dolist (dest dests)
(let ((name (plist-get dest :name))
(transform (plist-get dest :transform))
(params (plist-get dest :params)))
(unless (fboundp transform)
(user-error "No such transformation function %s" transform))
(orgtbl-send-replace-tbl name (funcall transform table params)))
(cl-incf ntbl))
(message "Table converted and installed at %d receiver location%s"
ntbl (if (> ntbl 1) "s" ""))
(and (> ntbl 0) ntbl))))