From the course: SketchUp Pro: Dynamic Components

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Add formulas to control the number of panels and size

Add formulas to control the number of panels and size - SketchUp Tutorial

From the course: SketchUp Pro: Dynamic Components

Start my 1-month free trial

Add formulas to control the number of panels and size

- Now that we have a user interface, we should connect it to the panel, so that we can control it with the UI. Let's begin by adding an attribute here, on the panel itself, for copies. This will control how many times the panel is copied. We already have a custom variable for that up here, Panel Number. So what I should do is target this field, and press equals, and then click on Panel Number up above. Now thinking this through, the way that Copies works, is it starts with an index of zero. So if copies equals zero, you have the original object. If copies equals, say, two, then you end up with two copies, but a total of three objects. So to make things a little bit more user friendly, I'm going to subtract one from this value, so that that will refer to the number of panels that we end up with, not just the number of copies that we have, plus the original. So I'm going to click over here in the white space to make that take effect. We also need to add an attribute where we can…

Contents