Event-Driven Macros

Ovaj dio opisuje kako dodijeliti Basic programe programskim događajima.

Možete automatski izvršiti makronaredbu kad se dogodi neki softverski događaj tako da tom događaju dodijelite željenu makronaredbu. Sljedeća tablica pruža pregled programskih događaja, te u kojem se trenutku izvršava dodijeljena makronaredba.

Događaj

Dodijeljeni makro je izvršen...

Početak programa

...nakon što je LibreOffice aplikacija pokrenuta.

Završetak programa

...prije nego je LibreOffice aplikacija okončana.

Stvori dokument

...after a new document is created with File - New or with the New icon.

Otvaranje dokumenta

...after a document is opened with File - Open or with the Open icon.

Spremi dokument pod novim imenom

... Prije nego je dokument sačuvan pod određenim imenom (sa Datoteka - Snimi kao, ili sa Datoteka - Snimi ili Snimi ikonom, ako ime dokumenta još nije određeno).

Dokument je sačuvan kao

... after a document was saved under a specified name (with File - Save As, or with File - Save or with the Save icon, if a document name has not yet been specified).

Spremi dokument

...before a document is saved with File - Save or the Save icon, provided that a document name has already been specified.

Dokument je snimljen

...after a document is saved with File - Save or the Save icon, provided that a document name has already been specified.

Dokument se zatvara

... prije nego se dokument zatvori.

Zatvoren je dokument

... nakon što se dokument zatvori. Primijetite da "Sačuvaj Dokument" se takožer može desiti kad se dokument sačuva prije zatvaranja.

Aktiviraj dokument

... nakon što se dokument otvorio u prednjem planu.

Deaktiviraj dokument

... nakon što se dokument otvorio u prednjem planu.

Ispiši dokument

...after the Print dialog is closed, but before the actual print process begins.

JavaScript run-time greška

...kada se desi JavaScript run-time greška.

Ispiši sve Mailove Kombinirano

...after the Print dialog is closed, but before the actual print process begins. This event occurs for each copy printed.

Promjena broja stranica

...kada se broj stranica mijenja.

Poruka primljena

...ukoliko je poruka primljena


Pridijeli Makro nekom Događaju

  1. Choose Tools - Customize and click the Events tab.

  2. Select whether you want the assignment to be globally valid or just valid in the current document in the Save In listbox.

  3. Select the event from the Event list.

  4. Click Macro and select the macro to be assigned to the selected event.

  5. Click OK to assign the macro.

  6. Click OK to close the dialog.

Ukloni Pridjeljivanje makroa događaju.

  1. Choose Tools - Customize and click the Events tab.

  2. Select whether you want to remove a global assignment or an assignment that is just valid in the current document by selecting the option in the Save In listbox.

  3. Select the event that contains the assignment to be removed from the Event list.

  4. Click Remove.

  5. Click OK to close the dialog.