LoginSignup
0

More than 5 years have passed since last update.

LibreOfficeBasicからPythonマクロを実行する

Posted at

Pythonマクロを作り初めて、Clacで実行しようとした時、ツール ー> マクロ ー> 実行 と操作しなければいけないが、非常に面倒だ。

直接、Pythonマクロが実行出来ないか検索しても見つかりませんでした。
BasicのFunc()みたいにセルに「=○○○」と入力して使いたいが、どうしても見つかりませんでした。

海外のLibreOfficeの質問コーナーでBasicからPythonマクロを実行したいという記事を見つけました。これならなんとかなりそうです。

Execute a Python Macro (Function) From Base and Return Value to Base
https://ask.libreoffice.org/en/question/52125/execute-a-python-macro-function-from-base-and-return-value-to-base/

Answers<1>と<2>の両方共、BasicからPythonマクロを実行することが出来ました。
どちらか言うと<2>の方が使い勝手が良いです。

AnawersのみGoogle翻訳で翻訳して下記のページに載せています。
https://pocketcomputer.jimdo.com/libreoffice%E3%81%A7python-2/

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0