# Insert a list of attributes into a component. (With Ruby console)

**URL:** <https://forums.sketchup.com/t/insert-a-list-of-attributes-into-a-component-with-ruby-console/200601>\
**Category:** Dynamic Components\
**Tags:** ruby\
**Created:** [June 8, 2022, 1:27pm UTC](https://forums.sketchup.com/t/insert-a-list-of-attributes-into-a-component-with-ruby-console/200601 "2022-06-08T13:27:36Z")\
**Posts on this page:** 1\
**Showing post:** 31

<div class="post-metadata">

**Author:** ![ryan.moore](https://sea2.discourse-cdn.com/sketchup/user_avatar/forums.sketchup.com/ryan.moore/32/106089_2.png) [@ryan.moore](https://forums.sketchup.com/u/ryan.moore)\
**Post date:** [November 30, 2023, 6:50pm UTC](https://forums.sketchup.com/t/insert-a-list-of-attributes-into-a-component-with-ruby-console/200601/31 "2023-11-30T18:50:24Z")

</div>

Yes this can be added to the script. See this [thread](https://forums.sketchup.com/t/redraw-all-dynamic-components/77512).

> [@Redraw all dynamic components?](https://forums.sketchup.com/t/redraw-all-dynamic-components/77512/2):
>
> ```auto
> Sketchup.active_model.selection.grep(Sketchup::ComponentInstance).each do |s|
> $dc_observers.get_latest_class.redraw_with_undo(s)
> end
> 
> ```
> 
> Open the Ruby Console (Window) and paste

---

_[View the full topic](https://forums.sketchup.com/t/insert-a-list-of-attributes-into-a-component-with-ruby-console/200601)._
