ライブラリおよびモジュールの管理

Basic Libraries Containers

LibreOffice Basic libraries can be stored in 3 different containers:

To access macros stored in libraries of Application Macros or My Macros from another container, including the document container, use the GlobalScope specifier.

ライブラリの管理

ライブラリの新規作成

  1. Choose Tools - Macros - Organize Macros - Basic and click Organizer or click the Select Module icon in the Basic IDE to open the Macro Organizer dialog.

  2. ライブラリタブをクリックします。

  3. Select to where you want to attach the library in the Location list. If you select Application Macros & Dialogs, the library will belong to the LibreOffice application and will be available for all documents. If you select a document the library will be attached to this document and only available from there.

  4. 新規にライブラリを作成する場合は、新規作成... をクリックして、ライブラリ名を指定します。

ライブラリのインポート

  1. Choose Tools - Macros - Organize Macros - Basic and click Organizer or click the Select Module icon in the Basic IDE to open the Macro Organizer dialog.

  2. ライブラリタブをクリックします。

  3. Select to where you want to import the library in the Location list. If you select Application Macros & Dialogs, the library will belong to the LibreOffice application and will be available for all documents. If you select a document the library will be imported to this document and only available from there.

  4. 追加... をクリックして、追加する外部ライブラリを選択します。

  5. ダイアログライブラリの追加 で、追加するライブラリを選択します。選択したファイルに含まれるすべてのライブラリを一覧したダイアログが表示されます。

  6. ライブラリを参照用として挿入するのであれば、参照として挿入(読み取り専用) ボックスをオンにします。読み取り専用のライブラリは、完全に機能はしますが、Basic IDEで編集することはできません。

  7. 同名の既存ライブラリを上書きさせる場合は、既存ライブラリの置換 ボックスをオンにします。

  8. OK をクリックすると、ライブラリが追加されます。

ライブラリのエクスポート

  1. Choose Tools - Macros - Organize Macros - Basic and click Organizer or click the Select Module icon in the Basic IDE to open the Macro Organizer dialog.

  2. ライブラリタブをクリックします。

  3. In the Location list you specify where your library is stored. Select the library that you want to export. Note that you cannot export the Standard library.

  4. エクスポート... をクリックします。

  5. Choose whether you want to export the library as an extension or as a BASIC library.

  6. OK をクリックします。

  7. ライブラリのエクスポート先を選択してください。

  8. OK をクリックすると、ライブラリが追加されます。

ライブラリの削除

  1. Choose Tools - Macros - Organize Macros - Basic and click Organizer or click the Select Module icon in the Basic IDE to open the Macro Organizer dialog.

  2. ライブラリタブをクリックします。

  3. リストから削除するライブラリを選択します。

  4. 削除 をクリックします。

モジュールおよびダイアログの管理

モジュールおよびダイアログの新規作成

  1. Choose Tools - Macros - Organize Macros - Basic and click Organizer or click the Select Module icon in the Basic IDE to open the Macro Organizer dialog.

  2. 「モジュール」 タブ、または「ダイアログ」タブをクリックします。

  3. モジュールを挿入するライブラリを選択して、「新しいモジュール」をクリックします。

  4. モジュールないしダイアログの名前を入力して、OK をクリックします。

モジュールおよびダイアログの名前の変更

  1. Choose Tools - Macros - Organize Macros - Basic and click Organizer or click the Select Module icon in the Basic IDE to open the Macro Organizer dialog.

  2. 名前を変更するモジュールを間を置いて 2 度クリックし、新しい名前を入力します。

    Basic IDEの画面の下部にあるタブで、名前を変更するモジュールないしダイアログのタブを右クリックし、「名前の変更」を選択して、新しい名前を入力します。

  3. 変更後の名前を確定するには、Enter キーを押します。

モジュールおよびダイアログの削除

  1. Choose Tools - Macros - Organize Macros - Basic and click Organizer or click the Select Module icon in the Basic IDE to open the Macro Organizer dialog.

  2. 「モジュール」 タブ、または「ダイアログ」タブをクリックします。

  3. 「モジュール/ダイアログ」のリストで、削除するモジュールを選択します。サブ項目がある項目は、ダブルクリックすると下層の項目が表示されます。

  4. 削除 をクリックします。

warning

モジュールを削除すると、そこに含まれるプロシージャーおよび関数もすべて削除されます。


ドキュメントおよびテンプレート内のプロジェクトの管理

ドキュメント、テンプレート、アプリケーション間でのモジュールの移動とコピー

  1. モジュールやダイアログの移動とコピーを行うドキュメントないしテンプレートをすべて開きます。

  2. Choose Tools - Macros - Organize Macros - Basic and click Organizer or click the Select Module icon in the Basic IDE to open the Macro Organizer dialog.

  3. ドキュメント間でモジュールやダイアログを移動する場合は、リスト内で該当するオブジェクトをクリックして移動先へドラッグします。オブジェクトのドラッグ中は、移動後の挿入位置が水平線で表示されます。 キーを押しながらドラッグすると、移動ではなくコピーされます。

ご支援をお願いします!