Hello!
So I have an OO Basic macro that is attached to a document rather than saved locally, I want the macro to be executed whenever the document is opened but I can only assign local macros to the events instead of the macro attached to the file.
When I send the file to another computer, it still has the macro but it needs to be manually ran which is no fun.
I tried going to tools > macros > OpenOffice Basic and when I select the macro attached to the file and hit "Assign", the events seem to be for the OpenOffice application instead of the file itself, is there a way to assign macros to file specific events so I dont have to configure macros on every single workstation?
I looked through the documentation and other forum posts and could only find answers for local macros instead of file specific macros, sorry if this has already been asked
Thanks in advance!
Running a File Specific Macro On File Open Event
Running a File Specific Macro On File Open Event
Windows 10 Pro
OpenOffice 4.1.7
OpenOffice 4.1.7
Re: Running a File Specific Macro On File Open Event
I think if you use the menu Tools -> Customize -> Events you can get to the macros in the document. I cannot test that at the moment but give it a try.
OpenOffice 4.1 on Windows 10 and Linux Mint
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
Re: Running a File Specific Macro On File Open Event
Welcome to the Forums.
My knowledge of macros is very limited, but in theory if you have the macro attached to the file, rather than stored locally, and you assign the macro to run upon opening, it would only execute upon opening that file, since the macro wouldn't exist in any other files that you might be opening.
If that seems confusing, then try it this way:
OpenOffice opens -> Looks for macro -> Finds macro -> Executes.
OpenOffice opens -> Looks for macro -> Doesn't find macro -> Does nothing or reports an error.
Please note that the above is not tested, just based on some logical thinking.
My knowledge of macros is very limited, but in theory if you have the macro attached to the file, rather than stored locally, and you assign the macro to run upon opening, it would only execute upon opening that file, since the macro wouldn't exist in any other files that you might be opening.
If that seems confusing, then try it this way:
OpenOffice opens -> Looks for macro -> Finds macro -> Executes.
OpenOffice opens -> Looks for macro -> Doesn't find macro -> Does nothing or reports an error.
Please note that the above is not tested, just based on some logical thinking.
OpenOffice 4.1.7, LibreOffice 7.0.1.2 on Windows 7 Pro, Ultimate & Windows 10 Home (2004)
If you believe your problem has been resolved, please go to your first post in this topic, click the Edit button and add [Solved] to the beginning of the Subject line.
If you believe your problem has been resolved, please go to your first post in this topic, click the Edit button and add [Solved] to the beginning of the Subject line.
Re: Running a File Specific Macro On File Open Event
Please upload your sample file with the embedded macro code here. Then we will able to examine, why it not run.
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
Re: Running a File Specific Macro On File Open Event
In Tools Menu/Customize/Events Tab
At the bottom of the Dialog there's a combobox to select Openoffice or your document. Assign the macro from your document to your chosen event and choose your document from that combobox.
At the bottom of the Dialog there's a combobox to select Openoffice or your document. Assign the macro from your document to your chosen event and choose your document from that combobox.
Windows 10, Openoffice 4.1.11, LibreOffice 7.4.0.3 (x64)
Re: Running a File Specific Macro On File Open Event
Example:
On Windows 10: LibreOffice 24.2 (new numbering) and older versions, PortableOpenOffice 4.1.7 and older, StarOffice 5.2
---
Lupp from München
---
Lupp from München