I am trying to change dynamic component properties through ruby script. But an error occurs ( Invalild entity to animate ).
The syntax is as follows
nn = “component#7”
sang_def.set_attribute ‘dynamic_attributes’, ‘onclick’, “SET("#{nn}!Hidden",0);”
I’m using SketchUp 2021 version and I’m running Windows 10.
Most probably because the syntax is wrong. ( you are using wrong characters of double quotes " and not using or missing single quotes '… not proper usage of String literal etc. )
You can check e.g. the following topics regarding " Dynamic Components is a proprietary , closed-source native extension…" :