LibreOffice स्क्रिप्टिंग

Contents
Index 🔎︎

# Assigning Scripts in LibreOffice

आप LibreOffice में मेन्यू वस्तुओं, प्रतीक, संवाद, नियंत्रक तथा घटनाओं को मनपसंद स्क्रिप्ट (मॅक्रोज़)आबंटित कर सकते हैं.

LibreOffice internally supports the following scripting languages:

1. LibreOffice बेसिक

2. जावास्क्रिप्ट

3. BeanShell

4. Python

In addition, developers can use high-level languages, for example Java programming language, to control LibreOffice externally. The API reference is online at api.libreoffice.org.

## नई मेन्यू प्रविष्टि के लिए स्क्रिप्ट आबंटित करने हेतु

1. Choose Tools - Customize, and click the Menus tab.

2. Click Add.

3. In the Category list box, scroll down and open the "LibreOffice Macros" entry.

4. You see entries for "LibreOffice Macros" (scripts in the share directory of your LibreOffice installation), "My Macros" (scripts in the user directory), and the current document. Open any one of them to see the supported scripting languages.

5. उपलब्ध स्क्रिप्ट को देखने के लिए कोई भी स्क्रिप्टिंग भाषा प्रविष्टि खोलें. कोई स्क्रिप्ट चुनें.

6. A list of the script functions appears in the Commands list box. Select a function.

7. Click Add to create a new menu assignment. The new menu entry appears in the Entries list box.

## कुंजी संयोजन पर स्क्रिप्ट आबंटित करना

1. Choose Tools - Customize - Keyboard.

2. In the Category list box, scroll down and open the "LibreOffice Macros" entry.

3. You see entries for "LibreOffice Macros" (scripts in the share directory of your LibreOffice installation), "My Macros" (scripts in the user directory), and the current document. Open any one of them to see the supported scripting languages.

4. उपलब्ध स्क्रिप्ट को देखने के लिए कोई भी स्क्रिप्टिंग भाषा प्रविष्टि खोलें. कोई स्क्रिप्ट चुनें.

5. A list of the script functions will appear in the Commands list box. Select any function.

6. LibreOffice या राइटर (या जो अनुप्रयोग वर्तमान में खुला है) के विकल्प बटन को क्लिक करें.

   Selecting the option button sets the scope of the new key combination to be applicable in all of LibreOffice or only in documents of the current module.

7. Select a key combination from the Shortcut keys list box and click Modify.

## किसी घटना पर स्क्रिप्ट आबंटित करना

1. Choose Tools - Customize - Events.

2. Click Macro button.

3. In the Library list box, scroll down and open the "LibreOffice Macros" entry.

4. You see entries for "LibreOffice Macros" (scripts in the share directory of your LibreOffice installation), "My Macros" (scripts in the user directory), and the current document. Open any one of them to see the supported scripting languages.

5. उपलब्ध स्क्रिप्ट को देखने के लिए कोई भी स्क्रिप्टिंग भाषा प्रविष्टि खोलें. कोई स्क्रिप्ट चुनें.

6. A list of the script functions will appear in the Assigned Action list box. Select any function.

7. LibreOffice में या वर्तमान दस्तावेज़ में सहेजने के लिए चुनें.

   This sets the scope of the new event assignment to be applicable in all of LibreOffice or only in documents of the current module.

8. Select an event from the list and click OK.

## किसी अंतर्निर्मित वस्तु के किसी घटना के लिए स्क्रिप्ट आबंटित करने हेतु

1. अंतर्निर्मित वस्तु को चुनें, उदाहरण के लिए, अपने दस्तावेज़ में किसी चार्ट को.

2. Choose Format - Frame and Object - Properties - Macro.

3. In the Macros list box, open the LibreOffice Scripts entry.

4. You see entries for share (scripts in the share directory of your LibreOffice installation), user (scripts in the user directory), and the current document. Open any one of them to see the supported scripting languages.

5. उपलब्ध स्क्रिप्ट को देखने के लिए कोई भी स्क्रिप्टिंग भाषा प्रविष्टि खोलें. कोई स्क्रिप्ट चुनें.

6. A list of the script functions will appear in the Existing macros in list box. Select any function.

7. Select an event from the list and click OK.

## किसी हायपरलिंक पर स्क्रिप्ट आबंटित करना

1. हायपरलिंक के भीतर संकेतक को रखें.

2. Choose Insert - Hyperlink.

3. Click the Events button.

4. Select and assign as stated above.

## किसी चित्र पर स्क्रिप्ट आबंटित करना

1. अपने दस्तावेज़ में चित्र चुनें.

2. Choose Format - Image - Properties - Macro.

3. Select and assign as stated above.

## फ़ॉर्म नियंत्रण पर स्क्रिप्ट आबंटित करना

1. Insert a form control, for example a button: Open the Form Controls toolbar, click the Push Button icon, drag open a button on your document.

2. With the form control selected, click Control on the Form Controls toolbar.

3. Click the Events tab of the Properties dialog.

4. Click one of the ... buttons to open a dialog where you can assign a script to the selected event.

## To assign a script to a control in the LibreOffice Basic dialog

1. Open the LibreOffice Basic dialog editor, then create a dialog with a control on it.

2. Right-click the control, then choose Properties.

3. Click the Events tab of the Properties dialog.

4. Click one of the ... buttons to open a dialog where you can assign a script to the selected event.