| View previous topic :: View next topic |
| Author |
Message |
Henrik OOo Enthusiast

Joined: 15 Jan 2004 Posts: 118
|
Posted: Fri Feb 27, 2004 10:36 am Post subject: Moving modules from one library to another, reassign macros |
|
|
Hi,
I have a calc document with several sheets and quite a few buttons/controls. I want to move my modules from one library to another. The problem is that I have assigned macros to all my controls and after moving the modules, the controls will all point to macros that don't exist.
At the moment a control will typically point to a macro like this:
document:StandardLibrary.ModuleA.SubA
After moving the modules to another library they should point to:
document:NewLibrary.ModuleA.SubA
Is there another way than manually reassigning all the controls?
Henrik |
|
| Back to top |
|
 |
DannyB Moderator


Joined: 02 Apr 2003 Posts: 3991 Location: Lawrence, Kansas, USA
|
Posted: Fri Feb 27, 2004 12:28 pm Post subject: |
|
|
Having played with macros just a bit myself, I can understand why you might want to do such a thing.
All OOo documents are actually ZIP files of xml. Unzip the document into a folder. It will have at a minimum....
content.xml
META-INF / manifest.xml
There will probably be other XML files. Within the content.xml you will find your buttons. Alter the macro library they point it by editing the XML text file. Then re-Zip everything back up and rename the suffix from ".zip" back to an OOo document (such as ".sxd" for Drawing, and something else for Calc).
Here's another hint. Before saving your documents, first....
Tools --> Options --> Load / Save --> General
then uncheck the box that says "Size optimization for XML". (You'll be glad you did!)
A tool that might help give you insight as to the structure of your documents is my Document Explorer, which you can get at...
http://OOoMacros.org
a direct link is here...
http://ooomacros.org/dev.php#92225
http://sourceforge.net/project/showfiles.php?group_id=87718&package_id=92225
Simply download the program. Unpack. Double click on the Jar to run the program. (Written in Java -- does not require OOo at all. OOo does not need to be running, or even be installed.) It prompts you for an OOo document. Then after you pick one, it opens a window that allows you to explore the contens of the Zip file, and the XML nodes. _________________ Want to make OOo Drawings like the colored flower design to the left? |
|
| Back to top |
|
 |
Henrik OOo Enthusiast

Joined: 15 Jan 2004 Posts: 118
|
Posted: Fri Feb 27, 2004 3:22 pm Post subject: |
|
|
Thx a lot DannyB  |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|