This week we have another really interesting guest post that looks at aspects of AutoCAD some people would never even consider possible. Nick Williams shares his knowledge on the subject of attaching and exporting object data in AutoCAD. As always it is great to hear from readers who would like to share their ideas, tips and tricks on the website so I am really grateful to Nick for getting in touch. So, without further ado I am going to let Nick get started.
Attaching and Exporting Object Data in AutoCAD
This article was written by Nick Williams. Nick works at Acuity Training’s Guildford office primarily on their various CAD courses.
While AutoCAD is not BIM software it can be used in a way that replicates some of the features of Autodesk Revit. There are a few tutorials out there which discuss how to automate the process of adding room tags and room schedules in AutoCAD. This got me thinking; what else can I achieve in AutoCAD that is more commonly associated with a BIM workflow. In this article I will demonstrate how to attach COBie parameters to blocks and export them to excel, using AutoCAD Architecture.
Before we begin it is worth noting that BS1192-4:2014 lists a set of parameters used in COBie Data Drops (a standard Format Excel file). These parameters are what we will be using to create a property set in this article. For more information on COBie, you may find the following link useful:
At this stage, it might be worth noting that we are not suggesting that COBie Data Drops should be attempted using AutoCAD. We are using COBie parameters as a way to demonstrate how to add parameters to objects in AutoCAD and export them to Excel.
Creating Property Sets
Before you can attach parameters to the various components within your drawing, you will first need to create a property set, with all of the various parameters you require. To do this open the Style Manager, found in the Style & Display panel of the Manage ribbon tab. Alternatively use the command _AecStyleManager↵.
In the Style Manager navigate to “Property Set Definitions” found within Documentation Objects. This is where you will find all of the property set definition styles that exist within your drawing, including the default AutoCAD Architecture styles.
To add a new style click on the “New Style” button, or right right-click anywhere within the Property Set Definitions window and select “New”:
After naming your new style as you see fit, click on it to open the various options associated with your newly created style. In this case, we have named the style “COBie Type” and added an optional description.
Next, select the type of objects you wish to apply the property sets to. As we want to add property data to blocks, select “Block Reference” (A) from the “Applies To” tab (B):
Having selected the types of objects you want the property set definition style to apply to, you can go ahead and add the various parameters you want the property set to include by selecting the “Add Manual Property Definition” button (A) within the “Definition” tab (B):
After you have completed adding all of the property definitions you require (which in this case have been taking from BS1192-4:2014 Table A.10) your Definitions tab should look something like this.:
Finishing the process of adding property definitions by clicking “Apply” or “OK” to save your newly created property set definition style.
Attaching Property Sets and Adding Data
Now that you have created a Property Set Definition Style using the Style Manager, you can begin adding the property set to the various blocks within your drawing. To do this first click on object you wish to attach the property set to, in this case the bed, then select the “Add Property Sets” button (A) within the Extended Data tab (B) of the Properties palette:
At this stage you will be prompted to select which property set you want to add and you should be able to see the previously created property set:
After selecting the property set you want to add, the Extended Data within the Properties palette will populate itself based on the parameters you previously added to the Property Set Definition Style and you can now begin entering the relevant data for each parameter:
This process can be repeated for all of the objects in your drawing.
Exporting to Excel
After you have created and attached a property set style and filled out each of the parameters via the extended data tab, you may wish to export the data to an Excel file or similar. This might be for a number of reasons because an Excel file is an easily accessible file format and it may even be required as a deliverable at the handover stage of a project.
In order export the data you first need to create a schedule table style. Begin by once again opening the Style Manager found within the Style & Display panel of the Manage ribbon tab (alternatively use the command _AecStyleManager ↵), and select “New Style” this time from the Schedule Table Style menu:
After naming the new style, click the “Add Column” button within the “Columns” tab and begin adding the parameters that you previously created as property set definitions, note you can change the order of the columns by dragging the header cell:
Complete the process of creating a schedule table style by clicking the “OK” or “Apply” button.
Now that you have added a new schedule to the Style Manager and defined what you want it to show you are now ready to add it to your drawing. Do this by entering the command SCHEDULEADD ↵. Select the newly created schedule from the Style options of the resulting palette:
At this stage, you will be prompted to select the objects you wish to include within the schedule. Do this by clicking on one of the objects you wish to include and complete the move by hitting enter once you have selected one of the objects, and placed the schedule in the desired location.
Add further objects to the schedule by clicking on the schedule and selecting “Add” from within the Schedule Objects panel of the Schedule Table ribbon tab. Alternatively use the command SCHEDULESELECTIONADD↵.
When you are happy with the schedule and have added all of the objects to it, export the schedule to Excel by right clicking on the schedule and selecting “Export”:
At this stage, you will be prompted to choose the file format you wish to export to (A), including xls, csv and txt. As well as the location you wish to save to (B):
After clicking “OK” you should be able to navigate to the file directory that you specified and open the schedule in Excel:
Note, in this demonstration we have exported just three of the objects and associated parameters as an example.
To find out more about the training courses on offer from Nick head on over to Acuity Training.