Hi,
I have a macro (let’s call it X) assigned to 2 events (“Save Document” and “Save Document As”).This macro does some useful things to my document. However, I did some testing and found out that if macro X is not available in LibreOffice, an error message will show up:
A Scripting Framework error occurred while running the Basic script
vnd.sun.star.script:Standard.Module1.X?language=Basic&location=application.
Actually, this behavior is quite understandable. The assigned macro is not available which results in an error message. Now the problem is that when I send my document with the assigned macro in it to someone else, he or she will see this exact same error message. Again, understandable because he or she does not have my custom made macro available on their computer.
So what I was wondering is if it it possible to create a macro (and if so how) that clears all macro’s that are assigned to a document. If so, I could run this macro before sending the document to someone else. So, for example, if I first assigned 10 macro’s to 10 events, they would all be unassigned after I ran that one specific macro. Can it be done?