How to import AutoCAD BLOCKS with attributes

From Tygron Support wiki
Jump to navigation Jump to search

DWG drawings from AutoCAD can contain BLOCK data with specific attributes.CAD blocks are named groups of objects that act as a single 2D or 3D object. You can use them to create repeated content, such as drawing symbols, common components, and standard details. In this example we will be using theTygron NLCS Basis interpretatie Template as a Geo Plugin. This Geo Plugin contains a layer which can recognize an attribute from an incoming AutoCAD BLOCK. Let us first examine this Geo Plugin link to see how this works.

How to examine "Basis NLCS Interpretatie" template:
  1. Create a new project if your current project does not have the "Basis NLCS interpretatie" Geo Plugin.
  2. When giving your project a name select "Use existing Template" and choose "Tygron Dxf Template". This will make sure that the "Basis NLCS interpretatie" is added tot your new project.
  3. When your project is loaded, go to Tools and click on Geo Plugins.
  4. In the left panel click on "Basis NLCS interpretatie"
  5. In the right panel click on the GeoLinks tab to display all Links available in the Geo Plugin.
  6. Scroll down to locate the "BOOM BLOCK REFERENCE" and click on it. The bottom panel will open.
  7. In the bottom panel click on the "General" tab (if it is not already open).
  8. you can see that the Tygron Function "Standaard loofbomen" is chosen for this link. (Dutch for Decidious trees)
  9. Click on the next tab "Matching attributes" and notice that 2 attributes have been configured. One is called "LAYER" and the other "HEIGHT".
  10. Click on the "LAYER" attribute and note the value on the right side has been set to "BOOM BLOCKS". This value corresponds with the AutoCAD layer name when you export this project to a DXF Reference. To learn more about the import/export procedures when working with Tygron consult the following HOW TO's: How to create a Geo Plugin to import Buildings from a DXF, How to import a DXF, How to export a project to DXF.
  11. Click on the HEIGHT attribute. No value is attached to this because we want this value to be filled dynamically by incoming DXF files which have a HEIGHT attribute in one of their BLOCK layers.
  12. Next go to the "Mapped Attributes" tab and click on the HEIGHT attribute. In this tab you can match incomming attributes with a specific Tygron attribute. In this case the HEIGHT attribute is mapped to "FLOOR_HEIGHT_M". In this example the "FLOOR_HEIGHT_M" functions as the height of a tree.
How to import DXF with BLOCK attribute information:
  1. In this example we want to import a DXF which has a layer where trees are drawn. We also want these trees to be different heights instead of the standard Tygron tree height.
  2. Make sure that your DXF has the layer "BOOM BLOCK". In this layer the BLOCKS with the tree drawings must be located.
  3. You can also export your current Tygron Project to a DXF reference where all the layers from the Geo Plugin will be exported to AutoCAD layers. To learn how to do this got to How to export a DXF
  4. Make sure that these BLOCKS have an attribute called HEIGHT and that every tree has a numerical value attached to this attribute. This will correspond with the height of the actual tree. To learn more about BLOCKS and attribuites in Autocad visit:[https://help.autodesk.com]