Custom Attribute Report using Trimbles Attribute Reporter Script

Hi all, I’ve been creating Dynamic Components with custom attributes which I can use to quantify lengths, areas etc… in Excel.

I’ve tried using Sketchup 2016’s Generate Report option, but as my model contains a number of DC’s, my computer seems to lag at each stage 1) after I click generate report, 2) when I edit a report 3) when I press continue after my selections.

Because of this I’ve looked into the option of a custom ruby script (which Trimble has an example of on their website).

I’ve noticed though, that the same thing occurs (lots of Lag) and from my tests - ie: selecting a number of complex DC’s (particularly ones that have nested component copies inside) the lag is significantly worse and almost impossible to use.

  • Does anyone know how to modify this Attribute Reporter Script so it runs faster - by excluding nested components for example.
  • I’ve noticed this in the script
    Create some global structures to store our report data in as

    it is built. Note that this is a RAM intensive approach, so extremely

    large reports could run into memory problems.

    @report_data = []
    @totals_by_att_name = {}
    Is there another way that’s not so RAM intensive??

*** In the end what I want is only a list of certain attributes (specifically ones starting with qx - eg: qxRoofArea)
*** I don’t need a list of all nested components, my calculations are made in the parent component and while there may be dozens of attributes used to calculate things, a component may only have 1 or 2 qx… attributes which I need to count in the end…

Also, because I’m counting many of my attribute values in excel, it would be much better if each component instance was listed separately rather than grouped together with a quantity of X. That way I can sum the attribute column without having to reference the quantity column. Does anyone know if this would be possible…



Hi Nathan
As an alternative workflow solution I suggest

You can customize the reports to suit your needs, without the quantity, maybe all level 1, and pick the required attributes, (name reports as window schedule, upper wall framing, bathroom tiles.)…save this as a template with other favorite layers, blocks embedded.

As it is quite likely that each area can be rationalized to footings, floor frame…gyprock…windows, doors… then match each section with the same layers, same report names, same component file names" .

On completion a selection can be made a component, right clicked and saved as like “job#wallframe”, “job# gyprock”,etc,…Now you can open each area and get a report that you can match to the section title. So the report writer does the job in manageable chunks

You could initialize dummy folders (timber single storey, brick veneer single story, timber double storey…) with all the appropriate files could then be used as the template your jobs, easy to overwrite an empty “job# gyprock” etc.

In regards to complex components,I give them an ability to be simplified through a process of exploding, outer shelling, exploding… so I am left with a data wrapper with raw geometry, a non functioning DC, which can be swap with itself if required to update. Of course its better to have a scripts to place and simplify the DCs


Thanks Philip. Much appreciated. Ive actually tried this approach. I first created an incredibly complex window component and have opted to dumb it down into exploded window sizes. So instead of just one dc window, i now have dozens. Just hope i see a significant increase. Just as a secondary note. There are a few things id like to do in a ruby script. I dont suppose you’d know anyone who’d be interested in some contract work scripting a few things for me. Dont get me wrong i have dabled in ruby but i just dont seem to get the time.

Thanks again for the reply…

Cheers Nathan

I am in a similar position myself, I am still using AutoCad to do my takeoffs and layouts via VBA. However I am moving towards a Sketchup solution. Initially waited on Sketchup programmers with their latest release, but DCs are the same, some improvement in reports, but still nothing exciting. So…

I am just starting to put together some Ruby, so perhaps not enough experience myself, however I am sure there are developers who could do the work, this site or SketchUcation

Personally I would like to see a free public solution(s), otherwise everyone are reinventing wheels, if not another DC cabinets.

I am frantically trying to set up custom drawing components to use for house design / estimating. I’m getting there but it seems like 3 steps forward and 2 back. Just when I see the light at the end of the tunnel, I find some limitation with sketchup’s dynamic components. I just posted a new thread Formulas replaced with Values when changing multiple Dynamic Component Options. Yet another weird result from using dynamic components which requires a work around.