Most in the construction industry is familiar with the report from McKinsey a few years past as well as others. The report outlines how Construction lags behind almost every other industry in terms of productivity. It looks something like this…
Shortly after Autodesk acquired PlanGrid was when I really started to get annoyed about these statistics. It was during an evening dinner hosted in Seattle for local construction industry leaders. Autodesk and PlanGrid were presenting their vision of the future together.
In attendance were competitors, trade partners, general contractors and owners from the all the firms you think of when you think Seattle construction. Generally speaking, it was a good meeting. That is until a particular Autodesk executive took his turn at the microphone.
Like a well rehearsed orchestra, out comes the productivity chart with his statement that construction productivity has been flat for 20 years. Without skipping a beat, he informed the group that the ONLY explanation was that as contractors, we’ll “Work as Slow as you let them or as Fast as you Make them.“.
Anecdotal stories from industry trades men and women always made me suspect that data was misleading. Stories of how a 1 million sq/ft hospital use to be a 5 year project and now a good team can knock it out under a year. We’ve shifted a lot of work from the field to the shop and there’s really no benefit? Nonsense!
Sometimes when you start making improvements the benefits don’t first appear where you think. When you first turn on the A/C in a home in a warm humid climate, you start feeling more comfortable almost immediately. Except the first thing to lower is humidity, not temperature. Improvements in the construction process starting in the early 2000’s had benefits, they just may not have shown up in the poor metrics historically used to measure productivity. Similar trends were observed with technology in general. There was a lag between Silicon Valley tech’s offerings and results in business processes. It takes time to realign business ecosystems.
An Alternate View
My nature is to question everything and everyone. Even I don’t escape this scrutiny myself as I’m usually my toughest critic. I’ve encountered too many instances where reality was 180 degrees opposite of what was considered obvious.
While that McKinsey report was important for our industry, it’s also been very misused. Instead of the explanation being that we work as slow as allowed and as fast as we’re made to, I have another theory. The software we’ve been sold for 20+ years promising increased productivity and efficiency has done nothing.
To be fair, this story isn’t limited to Autodesk as plenty of other software vendors like to misuse this productivity data. I also don’t think technology has had zero benefit either. The debate on either side is largely hypothetical. Rather the problem is more complex and the description of the problem is also likely flawed in many ways.
What’s Behind The Numbers
The first place you need to look, is where do the numbers come from? McKinsey’s data comes from a number of sources including international. In the US, that data comes from the US Bureau of Labor Statistics. Only recently did the BLS start aggregating data from specific construction sectors. Those sectors are as follows…
Single Family Residential Construction
Multi-Family Residential Construction
Industrial Building Construction
Road and Bridge Construction
Prior to getting these more sector specific numbers, they simply applied productivity from Single Family construction to the entire construction sector as a whole. Data points simply weren’t available for anything better. The above sectors don’t accurately reflect much of commercial construction where software and services dominate the focus of sales efforts by vendors.
Simply put, we’re measuring a lot of different things. Measuring them poorly and lumping them all together to get a half-assed number. They’re not good numbers but they are better then nothing. Even the BLS talks about the difficulty in obtaining good data due to various factors. One such factor is that labor from subcontractors is NOT included in the data. It’s treated like purchased materials for the purposes of BLS data collection. Subcontractors were predominantly where early prefabrication occurred. Not at the general contractor level.
That begs to question, as we move more to product manufacturing in construction, does more of that dollar value shift out of the productivity stats? It doesn’t shift labor equally to the shop as there’s still onsite assembly needed. Much like outsourcing anything, it’s not a 100% shift in labor as there’s now project management involved when outsourcing so labor actually increases. I suspect a shift to industrialized construction will not show well using current productivity measurement methods. We’ve separated the manufacturing and assembly resulting in increased labor. How does this affect the numbers?
But don’t take my word for it, dig into the data and publications yourself. There’s some good reading.
While construction productivity is a story our industry needs to hear, we need you ensure the data is used within the proper context. To start with, those “Productivity Charts” don’t actually report “Productivity“. Rather, they report “Productivity Change“. Those are two vastly different things.
If you compared the most vs least productive activities against each other over time, one will likely show drastic improvements in one while the other shows little. That doesn’t mean the activity with little improvement is somehow the laggard or in drastic need of disruption. Simply put, some activities have more low hanging fruit than others.
Secondly, the nice things about charts is you can make them say anything. Looking at that earlier productivity chart, did Agriculture, Manufacturing and Construction all magically start out with equal productivity in 1947? Unlikely. Let’s look at that data in a complete reverse manner…
Same exact curves, but displayed differently. Is Construction a laggard or did Agriculture and Manufacturing just get their shit together finally?
Construction has so many variables and is so difficult to compare, that most of these charts compare against dollar value for lack of anything better. That is likely the best number to use as poor as it is, but Dollars to Hours ratios are not the same across trades, materials, geographic regions, construction types, etc. Nothing has perfectly equal economic value.
Don’t get me wrong. I’m not suggesting Construction is the lens that other industries should look at themselves through. Having transitioned from Manufacturing to Construction in 2008 myself, I see a lot we’re doing wrong and there’s dirty laundry everywhere. However when you look at the same data from a different perspective, it suggests that there’s more to the story. It’s not the picture much of the industry prognosticators and technology pundits suggest in an effort to peddle their wares.
Dissimilar Manufacturing Models
When you think of Manufacturing and increasing productivity what do you think of? High volume standard products? Or do you think of single individual custom products? Now how about construction? High volume standard buildings or custom?
Most of the world is made of standard products not custom. From milk cartons to dental tools to cars, most everything you use is a standardized product. If not, they’re assembled from standardized products. Productivity gains in manufacturing come from highly refined processes, assembly lines, standardized parts, simplification and automation. These things take significant overhead investment and volume to recoup the capital they require. There are millions of products on the market and each of those have a scale of units sold.
This isn’t really the case for construction. Construction is predominantly a large custom machine assembly activity. While there’s an increasing number of “products” going into a buildings, the ratio of standard products to custom will never be the same. Where a manufactured product requires custom parts, there’s usually a ‘volume’ component to the equation. And where there’s parts in a product, they’re assembled in similar or the same way in each unit. This also isn’t the case for construction now and never will be IMO. It’ll trend toward manufacturing, but the movement in that direction will always be less than the gap that still exists for much of commercial construction.
One last contrast between manufacturing models is at the task level. Much of manufacturing is automated or comprised of single person tasks. Contrast this to construction where due to size and scale, many tasks are performed using multiple people. It’s far easier to automate one person than an entire team.
Scope and Scale
Another key difference between manufacturing and construction is in the scale of the activity. In a nutshell the larger physically a product is and/or the more parts/complexity it contains the longer the cycle time. We can buy most any power hand tool with almost zero lead time. A major $250-500k machine tool like a 5-Axis mill is going to have a lead time from a few months to even a year or more depending on backlog.
A building is really just a large machine. Likely the largest machine that’s commonly built. And it’s complexity is likely only rivaled by products like a jet airliner. It should be noted that a 737 from order to delivery takes about 24 months and that’s a multiple unit production activity with a sometimes decades long design process.
One reason size matters is distance, Everything I need to assemble most products can be within an arm’s reach or done on an assembly line (multiple units). Have you considered the distances of material and workers in construction? Vertical transportation alone in a high rise is a significant factor in productivity. Same components…just higher up in the air. It’s not really fair to compare manufacturing productivity with the productivity of building a cross country highway. And when was the last time you’ve had the entire population of a city core commuting through your manufacturing facility while you’re moving materials into position? Does a factory floor material handler need oversize load permits? Coordinate a city street shutdown for a crane pick?
If you look at the history of manufacturing, a lot of work has been outsourced globally. In the last 2 decades, a lot of that work has been brought back. With a focus on reducing complexity, ease of manufacturing and assemble (DfMA) manufactured products have become…simpler. Electronics and computers now replace complex mechanisms,
Construction on the other hand is trending in the other direction. Prefabrication and modularization takes added time and materials making things more complex. That complexity in manufacturing is a trade off for simplicity and safety in assembly on site…the actual build. It’s also what’s required to speed on-site construction and scale a physical location that can’t easily be scaled. It doesn’t in itself save time or material in many cases. It can actually increase these factors.
Simply put, product manufacturing used raw materials to make parts to make products. Construction used raw materials to make it’s product…little use of parts. Industrialized construction is inserting “product” into the process. That’s an extra step that didn’t exist before and productivity is not likely to be the first result you’re going to see. The benefits are elsewhere not productivity (quality, safety, scalability, speet of assembly/build, etc.)
In addition to prefab and modular trends, systems are more complex and new materials being developed in the name of energy efficiency and safety. With these systems comes significant financial risk. You could recall entire product lines and replace them for the price of a failed construction project like the Harmon Tower in Las Vegas. Do a quick internet search for the litigation around construction failures using Aquatherm piping in the US….a product that’s proven itself in other markets but was often misused during it’s entry to the US market. When you insert new risk, it’s going to cost money and/or time.
Customer Business Models
Everyone wants an iPhone. It’s trendy like many products. How many people want the same home or office? How many building owners even use their building the same way? Buildings aren’t bought the same way or using the same criteria as manufactured products. The financing isn’t even the same.
Value is defined by the customer and what they’re willing to pay for. For products, it’s typically reliability, utility, fashion and/or often price. In construction, those things are important too but there are other factors. Some of those other factors often cause waste in other areas like labor and materials which cast a dark shadow on productivity.
Lets examine a couple real world examples I’ve seen….
Example 1: Hospital construction schedule necessitates overtime. The following week, it’s layoffs and a complete shutdown. Why? The healthcare company wants to buy another chain and an open construction product on the books creates an obstacle for the bankers, accountants and lawyers. No worries, it’ll pick back up in 6 months. In the mean time, you have a huge hole in your schedule with no time to fill. 6 months from now, you’re already booked and the labor halls have empty benches. How’s your productivity now? Ultimately the customer did what made sound business sense for them but injected added cost and waste into the process.
Example 2: Your doing a tenant improvement (TI) project. There’s another team doing the Shell and Core. You could really make use of their tower crane but they’re going to demobilize. After all, they work for the developer who wants to take their money and move on. Again, sound business for the developer, but which costs time and productivity to the tenant’s TI.
No Waiting or Digitization Required
How many projects do you know where the construction schedule is ahead of the design schedule? All to common right? We don’t have time to wait while 100% of the design is finalized. We make calculated decisions based on risk of change and move forward. Construction has a low digitization rate and lacks sophisticated supply chains. In practical terms this means construction is VERY agile. That’s right…Analog IS Agile.
All those digital tools and integrated workflows. None of that is needed to build. All you need are People, Material and Tools. Simple materials and simple tools. And simply put, until recently, the technology did not exist to properly manage that volume of data is a collaborative way. The Cloud has really helped here but it’s use as a collaborative tool in construction is still in it’s infancy.
Another key difference between construction and manufacturing is the economic risk. Factory expansions get canceled or accelerated. But there’s also market research into number of customers and many other factors. It’s easier to scale your plans up/down or outsource fabrication and still get a large portion of your desired value. In construction, your customer is typically buying 1 of something. Half a fence isn’t 50% effective so it’s scalability during economic uncertainty is less elastic. We might scale back quality of furniture or advanced systems for energy savings but the building will get built or not. There’s not a lot of in-between.
Construction is also the largest capital investment someone will make. In a short decade (2008-2018), we went from a “Labor shortage“, to “Never Have enough jobs again” to “Labor shortage“. That type of economic swing does not lend itself well to investment in construction. It also doesn’t help you invest in building an industrial complex for construction. Detroit’s automotive industry, with it’s existing infrastructure has almost went out of business more than once in my lifetime. There’s no significant workforce still building cars by hand.
Accelerate that business cycle from my 50 years of life to a decade. Trying to build a brand new infrastructure to support industrialized construction isn’t going to happen over night. Most think Katerra failed. I think it was a hell of a win. To do what they did at the scale they did for as long as it went on was impressive. But it was an anomaly at best. Likely only facilitated by undisciplined business evaluations by speculators looking for a unicorn. Financial gamesmanship allowed Katerra to do what they shouldn’t have been able given the timeline involved. They paid dearly for that gamble. The industry as a hole has benefited. Industry innovators and disruptors often only serve to break the dam. Others behind it are often the floodwaters you were expecting.
Different Social Engagement
Construction is also a very social activity. This repeats each and every time. Manufacturing on the other hand is social during design and perhaps production startup. Even then it’s still considerably less social. After design and process definition, manufacturing becomes very transactional. When’s the last building you saw go up that was on auto-pilot? I don’t see the consumers of the built environment purchasing transitionally as a rule of thumb outside a few narrow edge cases.
Additive manufacturing (3d Printing) is perhaps the best hope of an “Auto pilot” for construction. It’s the sexy new thing in all the trade media publications and news articles. But I’ve yet to see a mechanical room printed in 3d. I’ve not seen how they’ve 3d printed embedded conduit or voids for electrical. And I’ve not heard of any new record tall skyscraper built this way. When Boeing has the largest buildings on earth (by volume) to build a jet, imagine them larger to build a 40-story highrise and make those production facilities mobile. That’s what we’re up against.
The last difference I’ll highlight is the regulatory environment construction operates under. Does the city council and their various committees dictate the size, quantity or color of the buttons on the machine you’re manufacturing? Do community groups protest the look of your products and demand that they have a similar feel as the rest of the products in your home?
Safety is another where the regulatory differences are striking. No industry is exempt. But they are targeted. Be it fishing, robotic cell design, chemical processing…there’s usually a limited scope to much of the regulations being pushed in the manufacturing space. In construction, those regulations sweep broadly across the whole industry. Much of this is insurance and litigation driven as well. In these cases, time is money and money wins. I’ve yet to buy a car and have a discussion with a dealer about bonding, lien wavers, or if my coverage will be OCIP or CCIP (Owner Controlled vs Contractor Controlled Insurance Plan). Financing a car is fairly straight forward. A building is not. Risk drives this and it will affect productivity.
I’m certainly not disputing the value of safety. However every moment you’re setting up/taking down safety gear and not holding a pipe is increased labor cost. In a manufacturing world, those measures tend to be more permanent, not repetitively relocated. They’re also more easily automated in manufacturing if human waste can’t be extracted any other way.
That’s a Wrap
Again, the point of all this isn’t that I think Construction don’t need to improve or change. It does. Safety is critical. So is energy and material usage. The point I’m trying to make is this….We don’t need to be brow beat into buying anyone’s product. None of them are going to save our industry by themselves. Our industry is doing quite well and is headed in the right direction. It just takes time to change an industry and build and new industrial complex to feed it.
I hope the next time you hear someone casually throwing out construction productivity stats, you’re more likely to push back. Empty slogans and catch phrases have no place in disrupting our industry. Sound business and data driven decisions do. Don’t let them bull shit you any more.
A bit if Personal History
PS: The below photo is of my child hood home I moved into in 4th grade. It was built in 1975 in a rural part of Michigan with a county population less than 8500 residents. It was a prefabricated home. All floor plates, walls and roof trusses were delivered in 3 open top semi trailers and assembled via crane over a full concrete block foundation in the course of a day. That was 45 years ago and it’s still not mainstream today. Things change slower than you realize and only to appear to have changed quickly in hindsight. Industry disruptors rarely destroy entire industries overnight. While there’s a lot of runway ahead, if you objectively look back 10-15 years, you’ll see we’ve come a hell of a long way.
If you’ve not downloaded the Autodesk Fabrication Script Libraries lately, you might want to grab an updated copy. There’s been several updates over the last month. Here’s what’s changed…
DamperRotation Property (undocumented) has been added to all Debug, Job and Library scripts. Support for this property was added in 2017 but never documented. It’s there to support the rotation of Dampers on Fabrication Parts in Revit. It should be noted, that this value is Added to the Angle property of the assigned damper. As such, it acts as an Adjust and not an Override. e.g. Damper w/Angle of 90 + Rotation Property in the ITM of 90 results in a damper rotated 180 degrees.
StiffenerGroup Property added to the Autodesk Fabrication 2022.0 and later versions of the Debug, Job and Library scripts.
AirturnGroup Property added to the Autodesk Fabrication 2022.0 and later versions of the Debug, Job and Library scripts.
SplitterGroup Property added to the Autodesk Fabrication 2022.0 and later versions of the Debug, Job and Library scripts.
InsulationStatusLock Property added but listed as “Unavailable” as it stopped working in 2017. Added in the hopes it gets fixed in future versions.
StructureType Property added to the Autodesk Fabrication 2022.0 and later versions of the Debug, Job and Library scripts. Property was “Write Only” in 2021 and prior versions so was unable to display in prior versions.
Product ListHasCustomData Property has been added to all Debug, Job and Library scripts.
Product ListHasFlow Property has been added to all Debug, Job and Library scripts.
ItemPCFSKey Property has been added to all Debug, Job and Library scripts.
ItemCostByLength Property removed from Material Debug scripts (never really belonged there).
If you run Autodesk Fabrication as a multi-user installation, there’s a defect in the Configure Users utility. When you run the utility from a 2022 installation, it won’t read any of the user accounts you have configured.
In fact, the only way to login, is to use the Default Administrator account Autodesk uses if there are no users configured. It won’t read your Administrative account regardless of what the login is. To see the issue, you can use the following to login and see the problem…
Once logged in, there will be one account. You can make more but when you exit and come back in, those accounts don’t show up. IN fact, even the original Administrator account isn’t there, it’ll make a new one. The following image shoes the users accounts that were created in 2022 be repeatedly going into it. Next to it is the 2021 utility showing those same accounts. As you can see, they are there, its just 2022 won’t show them.
Note that all the other Fabrication products will read/honor the accounts properly. It only seems to be the Configure Users utility that had the issue.
How to Determine Which Version of Configure Users To Run
To make things ‘easy’, Autodesk chose not to add the version in the name of the shortcut. Simply looking for ‘Configure Users‘ shows a lot of indeterminate results.
To pick a particular version, Right-Click on one of the shortcuts and select ‘Open file location‘.
This will display a File Explorer window to the location of the shortcut you selected. As you can see below, the one I happened to pick was for CAMduct Components 2016. The product doesn’t matter, only the version, You can navigate back a folder then pick one of the Fabrication products for any version you want. 2021 and earlier will work.
Not sure if or when they’ll get around to fixing this. While 2022 has had a few issues fixed, they didn’t release any updates (yet) for 2021. Regardless if they fix it or not, it’s easy to work around by using any other version.
Does your fabrication shop lack confidence in your drafting/detailing department?
Have you struggled to get buy-in when trying to roll out new processes, technology or deliverables?
Did you wonder why? More importantly, do you KNOW why?
Getting to the Root of Trust Issues
My entire career spanning manufacturing to construction, fabrication shops have had trouble trusting the information they’re given. And there’s good reason. It takes time to master a domain and learn the work. And production staff are busy building and fabricating. They don’t have time to run into the office every time something is wrong. As a result, office staff take longer to train and often persist with producing lower quality work.
But there’s also a lot of reasons that are not good. Downright bad in fact because they’re simple to resolve. Things you’re NOT doing wrong but are causing problems. These trust issues are easily corrected if they’re understood properly. One such issue is fabrication tolerances that I categorize as Shop Math.
The Dynamic Between Tolerance and Rounding
I’ve had trouble explaining this verbally so I figured a more graphic (yet generic) representation would be in order. In basic terms, you need to use a rounding factor 1/2 the amount of your fabrication tolerance to achieve the desired result. As the title of this post suggests, a value of 1/100″ of an inch, can result in a deviation of 1/4″. That’s real Shop Math in practice.
My example uses both fractional inch and decimal to more clearly illustrate the point. You don’t want to get me started in why everyone should use decimal, that’s another post. But decimal also has the same dynamic, it’s just less hidden and more easily fixed. You get a lot less pushback in a shop by adding an extra decimal than by changing the denominator of a fraction to a number the shop says they don’t fabricate to.
Let’s take the following example..,
In this example, lets assume our tolerance is 1/8″ (construction field tolerances, that’s fairly common).
The TOP RED dimensions are all ROUNDED to the nearest 1/8″ to match our target Tolerance. A fairly common practice. The BOTTOM GREEN dimensions are all ROUNDED to the nearest 1/16″ which is half our target Tolerance.
Each graphic shows a line 6″ long. Half that is 3″. We’re going to make a gap and dimension from each end to that gap. Maybe it’s a weld joint in pipe or perhaps a mortar joint in concrete block. Doesn’t matter what to illustrate the problem.
For the graphics on the LEFT (Quadrants 2 & 3), the gap is just shy of 3/16″ of each side of middle to forced the dimension to round UP. For the graphics on the RIGHT (Quadrants 1 & 4), our gap just heavy of 3/16″ of middle to force the dimensions to round DOWN.
Rounding = Tolerance = Confusion = Mistrust
Let’s focus on the TOP RED in the following illustration…
If you take the two parts and add them, they vary by 1/4″. Adding 3/8″ (our rounded gap size) to either of them does not equal 6″ either.
Between these 2 examples, a mere 1/100″ difference in our gap results in a 1/4″ difference and neither adds up to the 6″ of the total length. This is a 1/4″ TOLERANCE because we set ROUNDING to 1/8″ to match our fabrication accuracy.
If you ever wondered why your shop doesn’t trust your drafting/detailing, this is one reason. The Shop Math just doesn’t add up. They see the sum doesn’t add up to the whole and leads them to question the accuracy of your drawing and your staff.
Rounding = 1/2 Tolerance = Trust
Now lets focus on the BOTTOM GREEN portion of our illustration…
Between the left and right (Quadrants 3 & 4) we’re still making the gap just shy and just heavy of 3/16″ from the center. As you recall, we said our fabrication tolerance target was 1/8″ but here, the dimensions are ROUNDED to 1/16″. This is HALF of our target fabrication Tolerance.
Here, it doesn’t matter of the dimensions round UP or DOWN due to the slight variation in the gap, the dimension are the same. Furthermore, if you add the parts, you get 6″.
As you can see, we had different results between rounding UP and DOWN when our ROUNDING value equals the Tolerance we’re trying to achieve. When we round to HALF the Tolerance, those small variations are masked and all our numbers add up.
So if you’re dimensioning for the shop, it’s important to realize this little change can mean questioning or trusting your data and staff. Additionally, if you take the time on the shop floor to explain WHY they see these differences, they quickly realize that the information that leads them to question the data (and your people), is also the very same data that’s most likely to be wrong. What IS accurate and didn’t change, is the geometry itself. This is an extremely critical point to highlight if you’re trying to get your shop to use automation and drive machine tools from CAD/BIM geometry.
The model/geometry, is the MOST right data we have. It’s just not human readable and what we provide as human readable is prone to errors such as these. This is one reason you’re seeing terms like “Model Based Enterprise” starting to float around in the Manufacturing space. It’s also a reason you’re seeing more shop go paperless, eliminating dimensions when possible by leveraging automation.
These efforts can be challenging and often require a leap of faith. But if everybody understands dynamics like this, it can be extremely helpful in moving all of your staff to more digital workflows. Because they trust the geometry and you eliminate what’s confusing them.
Autodesk Fabrication 2022 marks a decade that I’ve been updating various documentation for the program. As usual, in recent years not a lot has changed but there are a few changes. Here’s a review of the changes for the data I track…
Update (2020.04.08): Autodesk released the Extension for MEP Fabrication 2022 on April 8th. You can get it from the Autodesk Desktop App or from your Autodesk Accounts Portal (manage.autodesk.com). This restores the MAJ Import/Export functionality and access to Fabrication Reports. It does NOT install the RME to FAB add-in. So part of the below guidance is still needed. You’ll want to copy the ADSK_Export.addin file per the below instructions. The other file is no longer needed and Autodesk’s newly released Extension will overwrite what’s needed if you used the below guidance.
If you’re an Autodesk Fabrication user and loaded up Revit 2022, you may have noticed some key Fabrication Add-ins are missing. It happens most every release. Deadlines for product releases always trump add-ins. This year, all the installers were reworked too so there was extra work I’m sure.
Don’t fear, they’ll get to them eventually. Just keep an eye on the Desktop App for when the updated Add-ins are release. In the mean time, here’s a temporary fix…
Enabling Fabrication Add-ins
To get the Fabrication Add-ins, you’ll need Revit 2021 installed and have those add-ins loaded in there. From there, there’s 2 files you’ll need to copy to a different folder.
The first file enables MAJ Import/Export and Fabrication Reports. The second file enables the Fabrication RME Extension in the Add-ins Ribbon.
You copy them from this folder…
…to this folder…
Here’s what that looks like in Windows Explorer….
What This Looks Like in Revit
Once you copy those files, restart Revit to see the changes. Here’s a review of what that looks like…
A Parting Word
It should be noted that this work around should be considered “temporary”. You’re running 2021 Add-ins in 2022. The files you coped should be removed once the official 2022 Add-ins are released. This will ensure you get any fixes they may have added to the 2022 versions.
COD Script Library was updated for JOB and LIBRARY Scripts. You can download them for free here. Here’s a summary of changes.
In the past, there were 69 to 75 COD Scripts to export all the various properties to separate TXT files. Properties that have multiple entries per ITM like Connectors or Seams are still exported to separate files because the data columns don’t line up between them and there are multiple lines per ITM.
All other properties where it’s a single property per ITM like Spool or Material have all been consolidated to a single script and single TXT file. The WriteAllMiscProperties(Job).cod and WriteAllMiscProperties(Library).cod scripts are where you can extract all other properties so no matter what combination of properties you want, there’s less data files to sort through or scripts to run.
Improved Script Properties Display
The properties scripts were displayed script settings before running the script. They still are but additional properties are displayed where appropriate along with some additional properties the scripts now support (both covered later). In addition to the additional items, you’ll note that clicking theNo button no longer cancels the script. Instead, clicking No takes you to the Advanced Configuration (also covered later) where you can change some of those settings.
By default, the script looks to the root of your ITM Library folder of your database. This value can now be changed to point anywhere else. You may want to point to a folder of ITM’s outside your Configuration if that’s where you store your ITM’s. You can also scan further down the folder structure so you can perhaps skip exporting Duct ITMs but instead scan and export Piping ITMs.
Here’s what this looks like. Note that the path may use forward slashes ( / ). You can however paste a new path that uses backslashes ( \ ) and it should still work. There’s no option in COD Scripts to allow you to browse to a folder so make sure you type or copy/paste carefully.
Advanced Configuration – Export File (JOB and LIBRARY Scripts)
Similar to the Scan folder configuration, you can now also change the default export file name and location. Specifications for specifying paths are the same as above.
Also note that while you CAN specify “CSV” as the file extension, I recommend using “TXT“. When Excel sees a CSV file, it just opens it without giving you the ability to specify how data is interpreted. Using a “TXT” extension makes Excel prompt you for “How” the file should be read like which character is used as the delimiter or defining which columns are Text vs other data types.
Some numerical data or values can be interpreted incorrectly by Excel if you don’t explicitly tell Excel to treat them like Text. A good example of this is the size 1-1/2″ or 1-1/4″. Excel thinks these are dates and will display them as 1/1/2012 or 1/1/2014 respectively if you don’t explicitly tell Excel to treat them as Text. Using that “TXT” extension on the export file is a safe guard against this issue.
A lot more detail that you likely wanted but hopefully it’s helpful, here’s what that looks like….
Note you may see an extra slash character between the path and file name. This is can happen if your MAP.INI (Edit Configuration Utility) includes or doesn’t include an ending slash. I may add code to clean this up later but COD Scripts and Fabrication seem tolerant of this extra slash so no need to worry about it (or edit it out if you like).
Instead of editing the folder you’re going to scan, alternatively you can specify a wildcard to use to limit which folders to export data from. As an example, you could specify *WELDBEND* and properties will only be extracted for ITM’s within folders containing the name “Weldbend”. Wildcard specification is not CaSe SeNsItIvE. By default, the wildcard is ( * ) to extract from all folders. Here’s what that looks like…
Just like the Folder/Path Wildcard specification, you can specify a wildcard for which ITM files to extract properties from. As an example, you could enter *PIPE* and you would export only from ITM files that contained the work “Pipe”. Again, the wildcard is not CaSe SeNsItIvE. You can use both Folder and File wildcards to very narrowly specify your data export scope. Default wildcard is an ( * ) to extract from all ITM files. Here’s what that looks like…
Advanced Configuration – Delimiter (JOB and LIBRARY Scripts)
Data exports by default use a Comma ( , ) to create a Comma Separated Value file. If your Fabrication Database uses commas in folder names or ITM file names this can cause data fields to shift in Excel when opening the export file. If this is the case for you, you can specify a different character to use to separate the data fields in the export file. The Pipe ( | ) character is always a good “rarely used” character for this purpose.
As a side note, it’s not a good practice to have commas in folder or file names. You can read more about that here. This option is really here in case you’re stuck with commas and haven’t fixed them yet.
Advanced Configuration – Max Custom Data Index (Only Scripts that export Custom Data)
Only used for scripts that export Custom Data, you can specify the maximum Custom Index value. Unfortunately, COD scripts have no ability to determine how many custom data entries you have or which index numbers are used without jumping through some hoops. To work around this, you need to specify the maximum Custom Data Index value. The script will then loop through all those numbers and find which ones contain values and remembers them. It then exports only those custom index values so that the script runs efficiency.
By default the script uses 5000 as the maximum index number. But as you can see from the below example, the maximum index number is 10000 so we need to specify that. We look at all 10000 possibilities (it goes fairly quick) and takes note that there’s only 8 indices used and then extracts only those 8 from the ITM’s. In the past, the script would loop through all 10000 for each ITM really slowing things down. Now, even if your largest number is 6 or 7 digits (not recommended) the script will still be fairly quick.
Here’s what that Delimiter Character configuration option looks like…
In the past, if you didn’t like the export files names, where they went, or wanted to change the scope of which files or folders you extract data from, you could have always changed the COD script code yourself. You now shouldn’t have to. Hopefully this makes running these scripts a little more flexible and user friendly.
If you write COD Scripts for Autodesk Fabrication, take note. There’s now an Extension for Microsoft Visual Studio Code (VS Code) which is Microsoft’s free code editor. If you use Notepad or Notepad++ to edit your code today you may want to consider switching. The COD Extension has some really nice features. Color coding of your code is the most obvious as shown below. However, there’s a lot more than just color coding. Features like Auto-Complete, Folding Sections and Dimension/Option Picker are nice additions in addition to a lot more robust documentation.
Installing The Fabrication COD Extension
If you don’t already have it, you can download and install VS Code here…https://code.visualstudio.com/. Once installed, go to the Extension section, type FABCOD and click the Install button.
Once you’ve installed the Extension, you can review a summary of extension details here…
From here, you can review a couple of the key features and their keyboard shortcuts….
VS Code Feature – Mini-Map
Not a feature of the extension, but one reason VS Code is a nice editor is the Mini-Map which helps you visualize where you are your code.
FABCOD Extension Feature – Folding
One of the features the FABCOD extension exposes in VS Code is the ability to collapse/expand sections of code for Looping and Conditional function and other areas. When you move your cursor to the left margin, you see symbols that activate this functionality called Folding.
In addition to Folding sections of code, you can create your own areas of code to collapse/expand. These are Folding Regions and can be inserted (or typed manually using the proper syntax) by highlighting the code and pressing CTRL+SHIFT+/.
FABCOD Extension Feature – AutoComplete
Auto-Complete is another core feature of any code editor. VS Code’s Auto-Complete features is leveraged by the FABCOD extension. You’ll need to be editing a saved file with a COD file extension so the VS Code extension knows which code extension to use.
ABCOD Extension Feature – Hover Tips
If you hover over known functions/properties and their context can be determined, VS Code will display a tooltip for the function you’re hovering over. This can be a great way to learn coding as it’ll help you with the syntax.
FABCOD Extension Feature – DIM / OPTION Picker
One of the best features of the FABCOD extension is the ability to get suggestions for the Dimension (DIM) and Options. You can activate the DIM picker with SHIFT+F1 and the OPTION picker using SHIFT+F2 keyboard shortcuts. When using these features, you are presented with an edit box. You type the CID/Pattern Number you’re interested in and press Enter. You are then given a list of Dimensions or Options you’re interested in. It’s not fool proof because some patterns have variable DIM/OPTION values but it seriously helps none the less. Take a look here…
FABCOD Extension Feature – Additional Help
Sometimes you need added help for a function. The FABCOD extension is an open source project on GitHub (https://github.com/AgileBIM/FabCOD). This project contains added help for every function and property and is Auto-Generated and updated as the extension is developed. You can access this help from any of the popup ToolTips by clicking on the BLUE hyperlinked text.
FABCOD Extension Feature – AutoCAD Launcher
One of the other neat features of the FABCOD extension is the AutoCAD Launcher. Pressing F5 in the editor will initiate the script in CADmep. Simply Alt-Tab to AutoCAD and press enter. AutoCAD and CADmep must be loaded at the time for this to work. Due to Autodesk’s limitations in their API’s, this functionality does not work with ESTmep or CAMduct.
VC Code FABCOD Extension – Wrapup
There’s a lot more to VS Code that I won’t get into here. I’ve only covered the highlights of how it and the FABCOD extension can be used to help edit COD file in Autodesk Fabrication. As it’s an open source project, there’s instructions on how to become involved if you have the coding skills. You can also just head over and log issues or suggestions. (https://github.com/AgileBIM/FabCOD)
If you’re looking for a one stop shop for some of the Revit / Autodesk Fabrication resources which I recently spoke about during a recent MCAA Education series Webinar, you can them all wrapped up in this tidy page here…