Component Attribute added to empty skp file

Hi Dan
I have another Question. This is something I did before by accident and I cannot remember how I did it. What I did was to have the component option Box open even thought I did not have any groups or component selected. This would be a handy feature to have as you could have one place [The component option Box] where you can change all your imported pre-programmed components globally.
For example. I have five DC component that I drag in but they are all different width size. If I want to change all to the same width, I would have to select all of them Individual. Instead I could go the Component option box and just change the width and all will change. Basically I want my empty skp file to be a dynamic component before I start and I can save it with pre programmed attribute.


SketchUp Sage
This would be a handy feature to have as you could have one place [The component option Box] where you can change all your imported pre-programmed components globally.
You open the Component Options window from the Window menu (or the Dynamic Components toolbar.)

The EntityInfo inspector can also apply properties across multiple items in a selection set.


Hi Dan I know how to open the component option menu. But I did not know about the entity info applying across multiple items. Very interesting. Thank you. Still this is not what I am looking for. I want to be able to add component attributes to an emtpy skp. file and have the component window open showing these attribute. I want to use these component options on models that I have in a folder that work when I drag them into the empty skp file. Hope you get what I mean. I have done it before but I have forgotten how I did it. Maybe Post this on the forum. someone will know.


SketchUp Sage
Yes you can manually add attributes if editing a component’s file directly.
But you need to use a plugin like Aerilius’ AttributeInspector

Or if you have Pro edition, you select a component instance, and then open the Component Manager dialog.
Make changes, then Saves As Component again.

Refer to the Dynamic Components User’s Guide, it explains better.


I think you are mis-reading what I am saying. I am looking to add component attributes to a blank file and have the component option menu show when this file is opened. I cannot see how the plugin can do this. Can you send me a file skp that works like I am requesting.


SketchUp Sage
I do understand. You need to use the AttributeInspector. And you need to be a Dynamic Component geek to do this manually.

I am sorry I do not teach Dynamic Components, I’m a Ruby Extension programmer, and I mostly teach Ruby programming via the forums.

Try posting in the Dynamic Components sub-category.


Thanks Dan.
I am well versed in DC components. But this is not covered in the help files. Can you do with a ruby script easier?
What would you charge to do this. I am sure it not to difficult. I just need a handy way to do it quickly.

Kind regards

To which I replied:

No point Andreas already wrote a attribute editor, as well as others.

You just create a dictionary named “dynamic_attributes” attached to the model, and save it as a skp file in your components library. The skp origin becomes the component origin when you insert it into another model.

Tangentially - as recently covered in another thread…
Do NOT geo-locate the base ‘empty-model’ SKP/Template - as this will break how your DC inserts in a new model…

@TIG, I also mentioned to him about the old plugin that HonoluluDesktop had written, but I don’t know the status of it. Has anyone updated it since he died ?
Does it run under Ruby 2 ? etc.

From the Ruby console:

dict = Sketchup.active_model.attribute_dictionary("dynamic_attributes",true)

Will create the dictionary if it does not exist.

Or if you installed the AttributeInspector:

… and name it "dynamic_attributes"

[quote=“DanRathbun, post:4, topic:15546”]
I also mentioned to him about the old plugin that HonoluluDesktop had written, but I don’t know the status of it. Has anyone updated it since he died ?Does it run under Ruby 2 ? etc.
[/quote] I’m not sure.
Of course it’s reasonable easy to fix most incompatibilities, given enough demand…

Hi Dan
Still did not work. I am trying to use a empty skp file which can allow me to input component attributes without selecting any geometry. I have done it once before but cannot replicate what i did.
The idea is to have a empty skp file where I can drag in sub DC’s and they change to suit the attribute set in the empty file. This must be possible. Do you know someone that I can pay to have this done?
Kindest regards

No that part is NOT possible. The changing will NOT happen until later when your no-longer-empty-skp, now saved as a component, is inserted into another model.

Sorry, it is just the way that the Dynamic Components extension is written.

Can it be implemented in next version sketchup 2016? How can I suggest it or can you?

No way, much too late. Besides the company employees are not allowed to comment on future releases or products. (It’s insider-information and Trimble is a publicly traded company. It was the same with Google.)

And, because Dynamic Components is a Ruby extension, it is not subject to the same release cycle as the main application. So updates or fixes can be released for it at any time.

Write up a clear request and post it in the SketchUp Feature Requests category.

You should be aware that until your very last post (in this thread,) I did not fully understand what you truly wanted.

No, actually I see no need for this, at all. But I could be wrong. You need to add “use cases” to your request, so as to convince the doubters (like me.)

Thank you Dan you are very help full. I will do a video for the feature request. I think its a simple thing do. If you create a skp file called box why could you not access the component attribute without having to select any geometry in the file.
If you then create a box component in this skp file it becomes a child and so can be controlled by the parent component attribute.
The way it is set up at the moment is you have to be in edit mode on a component and then drag components into it in order to control these sub components. Not very logical. I am sure there must be a work around somehow

You can create components that way,… even dynamic components, but the “Dynamic Attributes” wizard dialog is not programmed to treat the model as a component definition, so the nested DC instances will not “see” the model as a parent until the SKP is later inserted into another model.

So is it possible to open a DC and see the component attributes window populated without selecting any geometry in the model.

Could this be programmed with a plugin?


I said NO, the “Component Attributes” wizard dialog is not programmed this way.

See there are issues, the model itself uses the identity transform. Nested components expect to be nested inside another component instance, which could be scaled or rotated or positioned some distance from the origin. I suspect that that DC engine that reacts to the parent being transformed, just would not work.

The Dynamic Components extension is a Trimble product and the access to that dialog is edition controlled, so noone should be doing any thing with it but SketchUp Team.

I had mentioned a very old plugin, did you look into that ?
I think it would open the component in another instance of SketchUp, you would do your changes, then close that 2nd instance, and the 1st instance would update the component in the original model.

But that was before they made the rest of the model dim when editing a component, and temporarily moved the axes to the component’s origin & transform.

Ok Dan so its looks like I am beat.
I will have to look for a different solution.
Thanks for looking at this for me.
I appreciate you imput.
If only the guys at sketchup could build in a dialog box which could act as a global setting or attributes or act as parent for all child components brought into a emtpy model or skp file.


Sent from Samsung Mobile

Hi Dan
Just tried replying and noticed that opera does not work on the forum, the reply button anyway.
Had an idea. Is is possible to have a parent component remain active, as in remain in edit mode?. This would solve my problem. If I could have a way of keeping a componet in edit mode this would give me the same results I am looking for.
The component attribute window would be active and any sub components would come into the permantly active edit mode parent. I am looking to have any dragged in component go into this parent with having to go into edit mode each time.
Hope you understand.

You would need to convince the SketchUp Team to change the behavior of the Dynamic Components extension, or SketchUp itself.

Could I write something that will not let the user out of a certain editing context ? I don’t know. (Don’t think so.) The API does not have a way of specifically setting the edit context. That is a user only function.

Would I ? Probably Not.

Double clicking on a component to enter edit mode is just too quick and easy. The user needs to have control and does.

Once they click outside the context, we can “see” this with API observer, but cannot and should not force the return to the edit context.

Why? Because the only way to do it would be to call an Undo on the last operation, and it could be linked to a string of model operations. So there is no way to guarantee that only the “exit edit mode” is undone.

Thanks again Dan I hope someone out there has a solution, The more I think
about this the clearer it is to me that sketchup has no way of controlling
multiple DC component. This alone should be good enough reason to have this
ability build into Sketch-up and the DC plugin could then draw of the Data
imputed [component attributes] into a dialogue box that would in-turn
control any DC’s that are brought into the Empty model.
I will have to pitch it to the team so.
Thanks again for you help

But if the components share the same attribute, you can already select them all and are able to change them all at once.

This is very true Jim
But the problem is I have about ten different attributes set different on each DC component. If I select say 10 cabinets DC’s and change the height only, all the width etc, will also change to the root Component that was selected of these 10. So you upset the setting of the others.
But thanks for your input.