26 February 2010

Ever find your blocks or xrefs are inserting in the wrong place or at the wrong scale?

It seems to be a fairly common support query we get from a number of our customers – “I’m using the AutoChart Xref Data command and my Xrefs aren’t showing in my charts”. If this has happened to you, the chances are that you’ve run into the dreaded curse of the INSUNITS variable in AutoCAD – you are not alone!

Prior to AutoCAD 2006 the setting used for this variable had little effect on most users and consequently, most people didn’t pay it any attention or even know of its existence. However, from 2006 onwards Autodesk introduced a feature to automatically scale inserts and blocks according to the value set in the INSUNITS variable. All very nice and I’m sure it’s an extremely useful function for numerous AutoCAD users, unfortunately, if you’re unaware of what it does, mixing INSUNITS between drawings can lead to problems when inserting blocks and Xrefs.

To better understand what effect the variable can have, first we can take a look at its entry in the AutoCAD Help File:


Source: AutoCAD MAP 2010 Help Documentation
So you can see there are numerous settings relating to the distance units used within a drawing. When AutoCAD is installed the default template is normally acad.dwt (or map2d.dwt for AutoCAD MAP). If you inspect the value of INSUNITS for this template (by typing ‘insunits’ at the AutoCAD command line) you’ll see (assuming it hasn’t already been changed since installation) that it is set to 1 (or, according to the table above ‘inches’).

17 February 2010

Using a Block ini file in Import Block

The AutoChart Import Block command is a useful way to import ascii data to symbolize data (such as core or CPT locations), but in its simplest form, it is limited to a single block definition for every data point in the file. This means that if you have to display different types of data, you have to run the command multiple times, changing the data file and the block symbol each time. There is however an easy way to use the command in a single operation and create different symbols for different types of data. It is also makes it possible to control which Layers are used for different symbols. To use this functionality, you need to define a Block Ini file and ensure that each different type of data has a unique identifier as the first attribute in the data file.

For example, the data file may contain all of the As-Laid Events for a Cable Route:
The values in the 3rd column provide an identifier that links to the block name to use with the symbol settings held in the Block Ini file: