TheSwamp
Code Red => AutoLISP (Vanilla / Visual) => Topic started by: boicottms on July 22, 2020, 05:44:32 AM
-
Hallo,
how can I reconnect an object's properties' field (say area, lenght, color or whatever) to a new object? I sometimes loose the original object, or I want to duplicate an attribute/text/leader formatted and with extra text then point them to different objects without the need to insert and format it every single time.
Tahnk you
-
If the only thing that has changed is the reference object, then the field can be read and the objectID string within the field replaced with the new ObjectID string provided the new reference object has the same property. This would require two selections, the text/mtext entity or Attribute sub entity and the reference object to get the new ObjectID string.
There is a lisp here that I wrote a week ago that does that.
https://forums.autodesk.com/t5/visual-lisp-autolisp-and-general/lisp-to-reassociate-multiple-fields-in-one-object-block-to-point/m-p/9630140#M402278
See if that works for you
-
Thank you, I'll check it.