Using programming there are various ways to associate persistent additional information such as string to many ONE objects, for example with the UserDefinedAttributes container (and related variants such as TextUserDefinedAttributes and ParaUserDefinedAttributes).
This information is then saved with the document maintaining the relationship with the respective objects
Is there a similar way, even with programming, to associate UNO objects just as permanently with other UNO objects without resorting to cross-references, fields or similar techniques?
I ask because with version 6.2 (today I use 6.2 and 7.4 in parallel) after creating a relationship between a data source and a database at each attempt to create new cross-references, in each document libreoffice opened generated every 10-20 seconds messages because it could not find the database and there was no way to reset and avoid it other than reinstalling libreoffice which I preferred to avoid for various reasons
I therefore look for an alternative solution under my control which, at least where possible, allows me not to depend on the application
Currently the shortcut I would like to use (not yet completed but partially tested) is to use userdefinedattributes (UDAs) both to associate each element (e.g. a paragraph, a table, etc.) with a unique string id and to create a list of similar ids associated with other items
For example, in the UDAs of a paragraph I insert both the id (for example “ah01”) and a list of ids of other paragraphs (for example “pr01, pr02, prxx”)
By creating enumerate map global variables during the document loading phase that associate each id (key) to the relative UNO object (the operation is quite fast and must be performed only from time to time for any refreshments) I solve the problem at least for my purposes
But I was wondering if there was a system similar to UDAs also for objects and even only dynamic (e.g. to be created during loading and keep it until the document is closed), which is possible in the DOM model of web pages
Thanks for any suggestions
PS: I do not use the enumerate map type structures provided by scriptforge which, according to the tests presented here by another user, seem to have significantly longer access and write times than the structures