This is an EXPERIMENTAL feature. Use with caution in production templates.
Overview
The Subsheet Widget provides a way to automatically create calculations that are dependent on the result of a master sheet. The typical scenario is a calculator likeportalFrameAnalysis which performs analysis on certain member sizes, but the design must be linked to and performed in timberMember calculators for each element.
Instead of manually creating the portalFrameAnalysis and each of the timberMember calculators and linking them, you only need to create the portalFrameAnalysis and everything is automatically synchronized!
API Structure
The subsheet widget can be dragged from the sidebar and has multiple conditions like the equation widget, but must have an array of objects for theresult.
Configuration Parameters
Unique identifier for each subsheet. Typically
string(row[x]) when iterating over table, which pulls the value in the Xth column of the 1st argument.Visible to user so should be meaningful. Best to have 1st argument have a column of labels like “Left Leg”, “Right Leg”. Example:
string(row[y]) when iterating over table.Subsheet name (e.g.,
timberMember)Any string that will match the “capability” key added to the subsheet (e.g.,
elementLinking)The preset to use for the subsheet (e.g.,
elementLink)Array of reference IDs of widgets in the subsheet that are shared. Within parent sheet these are accessed per special syntax below.
Reference ID of subsheet table widget that receives all the results export (e.g.,
link_table)The row of data selected in the subsheet (0-based). Typically a column in 1st argument table that has an incrementing integer (e.g.,
row[1] when iterating over table)Important Constraints
Critical Requirements:
-
The keys (e.g., id, name) must not have any data that is derived from one of the
commonInputwidgets. This will lead to cyclic calculation errors. -
The subsheets cannot have defaultValue formulas in any of the
commonInputs. For example, if connecting tomember, don’t set a defaultValue in the timberMember subsheet of=projectDefault(xx)in any preset or the defaultValue key. -
The
subsheetDatathat is mapped over must not have any data that is derived from one of thecommonInputwidgets.
Iteration for Multiple Subsheets
When the number of subsheets varies dynamically (e.g., based on the number of elements in a frame analysis), you can iterate over a table using themapRows function.
Dynamic Sheet Management
When the number of subsheets changes, sheets will be added or deleted accordingly. The subsheet input data will be preserved only if the newly created subsheet shares the sameid as the previously deleted subsheet.
Example: A beam analysis with 3 spans that changes to 2 spans will delete the 3rd subsheet. If the ids were [0,1,2] then [0,1], and later a third span is re-added with matching IDs ([0,1,2]), the previous subsheet will be recreated with all its old inputs.
MapRows Function
| Parameter | Type | Description |
|---|---|---|
subsheetData | string | Table to iterate over |
fn(tableRow) | function | Function that returns subsheet configuration object for each row |
Implementation Steps
1. Create Template
Create a template based on Portal Frame or Truss template.2. Add Export Table
Add a table for exported inputs (as you would for normal linking).3. Add Subsheet Widget
Add a Subsheet Widget and configure it according to the API above.4. Update Capabilities
Add/Update the capabilities array in the subsheet header:5. Reference Values
Reference the subsheet widget values throughout the master sheet using the special syntax below.Referencing CommonInput Values
When working inside the super sheet, use this special syntax to reference any commonInputs:Input Widgets
Lookup Widgets (Data Table or Shared Table)
Special Characters
When you have special characters (-, /, space), use square brackets instead of dots:
Example: Data Table Lookup
Usage Workflow
- Master Sheet Setup: Go to master sheet and set up your common inputs
- Subsheet Access: Go to the subsheet and results should be available
- Bi-directional Updates: Change common inputs in the subsheet and the master sheet will re-calculate automatically
As the UI develops, this usage section will be expanded with more detailed workflow examples.
Example: Portal Frame Analysis
Instead of manually generating the array of objects, map over each row in theelemExport table:

Best Practices
- Consistent IDs: Use consistent IDs for dynamically sized arrays of subsheets to preserve user input data
- Avoid Cycles: Ensure no cyclic dependencies between commonInputs and derived data
- Testing: Thoroughly test dynamic sheet creation and deletion scenarios
- Documentation: Document the relationship between master and subsheets clearly
This feature is experimental. Monitor for any unexpected behavior and report issues to the development team.