# Dynamic component (materials) nested into another DC

**URL:** <https://forums.sketchup.com/t/dynamic-component-materials-nested-into-another-dc/91779>\
**Category:** Dynamic Components\
**Created:** [March 26, 2019, 10:30am UTC](https://forums.sketchup.com/t/dynamic-component-materials-nested-into-another-dc/91779 "2019-03-26T10:30:15Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![conceptfolder](https://sea2.discourse-cdn.com/sketchup/user_avatar/forums.sketchup.com/conceptfolder/32/32254_2.png) [@conceptfolder](https://forums.sketchup.com/u/conceptfolder)\
**Post date:** [March 26, 2019, 10:30am UTC](https://forums.sketchup.com/t/dynamic-component-materials-nested-into-another-dc/91779/1 "2019-03-26T10:30:15Z")

</div>

Hello,

Hope you can help me. I am building up a library of kitchen components and I would like to have the option to change the carcass colour.

For instance, say I have a 600wide cabinet, but an option of two carcasses: white and oak. I am trying to build a dynamic component in which the carcass remains a component so I can play with the material behaviour and choose a colour, and that would be inside the 600wide cabinet component.

However, when I create the component and go through the options of the OVERALL component, I cannot pull down from the list, only when I go into the carcass component, which does not give me the shortcut I was intending to create. Is there a way to make this work better?

Thanks!

---

<div class="post-metadata">

**Author:** ![nnijmeijer](https://sea2.discourse-cdn.com/sketchup/user_avatar/forums.sketchup.com/nnijmeijer/32/66166_2.png) [@nnijmeijer](https://forums.sketchup.com/u/nnijmeijer)\
**Post date:** [March 26, 2019, 11:07am UTC](https://forums.sketchup.com/t/dynamic-component-materials-nested-into-another-dc/91779/2 "2019-03-26T11:07:34Z")

</div>

You will have to add the color options in the overall component as a list parameter. Then you link this parameter to the materials parameter of the subcomponent (carcass) to which it relates.

---

<div class="post-metadata">

**Author:** ![pcmoor](https://sea2.discourse-cdn.com/sketchup/user_avatar/forums.sketchup.com/pcmoor/32/3427_2.png) [@pcmoor](https://forums.sketchup.com/u/pcmoor)\
**Post date:** [March 27, 2019, 6:10am UTC](https://forums.sketchup.com/t/dynamic-component-materials-nested-into-another-dc/91779/3 "2019-03-27T06:10:37Z")

</div>

I suggest you make a “kitchen” template that has a material palette and have the DCs reference that. Then no need to make heavy components, repaint the palette, do a redraw and the DC updates. Try the example, manually redraw via right click menu (can do a short cut). If you believe this is for you, then we can add a simple script to redraw all.  
[kitchen.skp](https://forums.sketchup.com/uploads/short-url/rTEVMbkWZD8I6Ufi1Szwb5kkc5l.skp) (318.9 KB)

---

<div class="post-metadata">

**Author:** ![conceptfolder](https://sea2.discourse-cdn.com/sketchup/user_avatar/forums.sketchup.com/conceptfolder/32/32254_2.png) [@conceptfolder](https://forums.sketchup.com/u/conceptfolder)\
**Post date:** [March 27, 2019, 9:15am UTC](https://forums.sketchup.com/t/dynamic-component-materials-nested-into-another-dc/91779/4 "2019-03-27T09:15:55Z")

</div>

I have done this, and I think I may have gotten around it now 🙂

---

<div class="post-metadata">

**Author:** ![conceptfolder](https://sea2.discourse-cdn.com/sketchup/user_avatar/forums.sketchup.com/conceptfolder/32/32254_2.png) [@conceptfolder](https://forums.sketchup.com/u/conceptfolder)\
**Post date:** [March 27, 2019, 9:16am UTC](https://forums.sketchup.com/t/dynamic-component-materials-nested-into-another-dc/91779/5 "2019-03-27T09:16:31Z")

</div>

I will give this a go, not sure I understand it how it would work as I have hundreds of separate components. But will let you know later. Thank you!! 🙂

---

<div class="post-metadata">

**Author:** ![Zarloff](https://avatars.discourse-cdn.com/v4/letter/z/dec6dc/32.png) [@Zarloff](https://forums.sketchup.com/u/Zarloff)\
**Post date:** [May 3, 2019, 2:57pm UTC](https://forums.sketchup.com/t/dynamic-component-materials-nested-into-another-dc/91779/6 "2019-05-03T14:57:14Z")

</div>

Try the OPTIONINDEX Function.  
It allows you to pass the choice to a component inside the main component.  
I have demonstrated how I solved passing a choice to a sub-component within a sub-component in a post from yesterday, [Passing attribute instructions beyond the child level](https://forums.sketchup.com/t/passing-attribute-instructions-beyond-the-child-level/94606)
