<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Lazy Drafter &#187; AutoCAD Map 3D Tips</title>
	<atom:link href="http://www.lazydrafter.com/category/autocad-map-3d-tips/feed" rel="self" type="application/rss+xml" />
	<link>http://www.lazydrafter.com</link>
	<description>AutoCAD tips for the lazy drafter.</description>
	<lastBuildDate>Wed, 01 Feb 2012 20:03:21 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Map 3D Query Macro and Script</title>
		<link>http://www.lazydrafter.com/autocad-tips/map-3d-query-macro-and-script</link>
		<comments>http://www.lazydrafter.com/autocad-tips/map-3d-query-macro-and-script#comments</comments>
		<pubDate>Wed, 02 Feb 2011 20:47:25 +0000</pubDate>
		<dc:creator>Josh Jones</dc:creator>
				<category><![CDATA[AutoCAD Map 3D Tips]]></category>
		<category><![CDATA[AutoCAD Tips]]></category>
		<category><![CDATA[AutoLISP]]></category>
		<category><![CDATA[Macros]]></category>
		<category><![CDATA[Scripts]]></category>

		<guid isPermaLink="false">http://www.lazydrafter.com/?p=934</guid>
		<description><![CDATA[Here is a macro combined with a couple of scripts that I wrote this week. What it does is import data from another drawing (containing street names in this case) with a Map 3D query based on a rectangular area. The Macro: ^C^Cscript;P:/GIS/XREF-CITY-MAP.scr;(alert "Pick two diagonal points to define the import area.");(setq firstp (getpoint "Pick [...]]]></description>
			<content:encoded><![CDATA[<p>Here is a macro combined with a couple of scripts that I wrote this week. What it does is import data from another drawing (containing street names in this case) with a Map 3D query based on a rectangular area.</p>
<p><strong>The Macro:</strong></p>
<pre>^C^Cscript;P:/GIS/XREF-CITY-MAP.scr;(alert "Pick two diagonal points to define the import area.");(setq firstp (getpoint "Pick first point: "));\(setq secondp (getpoint "Pick second point: "));\script;P:/GIS/IMPORT-STREETNAMES.scr;</pre>
<p>I&#8217;ll break it down for you. <span id="more-934"></span></p>
<p>The first part of the macro&#8230;</p>
<pre>script;P:/GIS/XREF-CITY-MAP.scr;</pre>
<p>&#8230;XREFs a map into the drawing so you can visually pan and zoom to your location. Here is the contents of &#8220;XREF-CITY-MAP.scr&#8221;:</p>
<pre>
-layer
n
X-BASE
s
X-BASE

-xref
a
P:\GIS\City-Map.dwg
0,0,0
1
1
0
</pre>
<p>The middle part of the macro&#8230;</p>
<pre>(alert "Pick two diagonal points to define the import area.");(setq firstp (getpoint "Pick first point: "));\(setq secondp (getpoint "Pick second point: "));\</pre>
<p>&#8230;creates an alert box telling the user to pick two diagonal points to define a rectangular area which will be used in the query. Notice that I am defining the coordinates for &#8220;firstp&#8221; and &#8220;secondp&#8221; and using back slashes (\) to pause for user input.</p>
<p>The last part of the macro&#8230;</p>
<pre>script;P:/GIS/IMPORT-STREETNAMES.scr;</pre>
<p>&#8230;defines and executes the Map 3D query. Here is the contents of &#8220;IMPORT-STREETNAMES.scr&#8221;:</p>
<pre>
-xref
d
*
ADEDRAWINGS
al
d
P
a
P
P:
x
at
P:\GIS\Street_Names.dwg
x
adequery
c
p
c
x
d
l
w
c
!firstp
!secondp
p
and
la
*
x
e
d
ADEDRAWINGS
de
Street_Names.dwg
x
</pre>
<p>Notice that I used &#8220;!firstp&#8221; and &#8220;!secondp&#8221; in the script to input the coordinates defined earlier in the macro.</p>
<p>I hope this helps you see the power of macros and scripts. If this is foreign to you, take some time to <a href="http://www.lazydrafter.com/autocad-resources/create-a-custom-toolbar-in-autocad">learn the basics of creating macros.</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.lazydrafter.com/autocad-tips/map-3d-query-macro-and-script/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Contours From Shape Files With Elevations</title>
		<link>http://www.lazydrafter.com/autocad-map-3d-tips/contours-from-shape-files-with-elevations</link>
		<comments>http://www.lazydrafter.com/autocad-map-3d-tips/contours-from-shape-files-with-elevations#comments</comments>
		<pubDate>Mon, 27 Oct 2008 12:00:14 +0000</pubDate>
		<dc:creator>Josh Jones</dc:creator>
				<category><![CDATA[AutoCAD Civil 3D Tips]]></category>
		<category><![CDATA[AutoCAD Map 3D Tips]]></category>
		<category><![CDATA[Macros]]></category>
		<category><![CDATA[Map 3D Expressions]]></category>
		<category><![CDATA[Map 3D Object Data]]></category>
		<category><![CDATA[Scripts]]></category>
		<category><![CDATA[Shape Files]]></category>

		<guid isPermaLink="false">http://www.lazydrafter.com/?p=583</guid>
		<description><![CDATA[Murph has written an excellent post on creating contours from shape files with elevations. I have been using this method for a while now. In fact I have written scripts and macros to automate importation of contour data into my drawings. Simply start a blank drawing, import the ESRI contour shape file using Map 3D, [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://map3d.wordpress.com">Murph</a> has written an excellent post on <a href="http://map3d.wordpress.com/2007/09/26/contours-from-shape-files-with-elevations/">creating contours from shape files with elevations</a>. I have been using this method for a while now. In fact I have written scripts and macros to automate importation of contour data into my drawings. <span id="more-583"></span></p>
<p>Simply start a blank drawing, import the ESRI contour shape file using Map 3D, save the drawing as &#8220;contour.dwg&#8221; (without quotation marks), and close it.</p>
<p>Then customize a script to import the contours and automatically put them on actual elevations based on their object data. Here is an example script to import contours from another drawing:</p>
<pre>
cmddia
0
ADEDRAWINGS
at
C:\[path-to-folder-with-contour-drawing]\contour.dwg
x
adequery
c
p
on
d
e
:ELEV@Default_contour
x
x
d
l
all
p
and
la
*
x
e
d
ADEDRAWINGS
de
contour.dwg
x
cmddia
1
&nbsp;
</pre>
<p>First, copy and paste the above code into Notepad (or similar text editor) and change the path:</p>
<pre>C:\[path-to-folder-with-contour-drawing]\contour.dwg</pre>
<p>&#8230;to point to where your contour drawing is stored.</p>
<p>Second, find the code: </p>
<pre>:ELEV@Default_contour</pre>
<p>&#8230;and modify it. This is a Map 3D expression and it should be modified to match the object data embedded in your contours. To figure out how to create your own expression to work with your data, let&#8217;s break it down. The basic expression is as follows:</p>
<pre>:[FIELD]@[TABLE]</pre>
<p>The code [FIELD] is a field name in an object data table called [TABLE]. If you were to type ADEEDITDATA on the command line and select a contour polyline, you would see something like this:</p>
<p><a href="http://www.lazydrafter.com/stuff/2008/09/contours00.png"><img src="http://www.lazydrafter.com/stuff/2008/09/contours00-300x209.png" alt="" title="contours00" width="300" height="209" class="alignnone size-medium wp-image-619" /></a></p>
<p>Notice the table name in this case is called &#8220;Default_Contour&#8221; and one of the field names is called &#8220;ELEV&#8221;. Hit OK to close the &#8220;Edit Object Data&#8221; dialog box.</p>
<p>Another way to look at object data is through the Properties palette. Click on a contour polyline, right-click and select &#8220;Properties&#8230;&#8221;</p>
<p><a href="http://www.lazydrafter.com/stuff/2008/09/contours01.png"><img src="http://www.lazydrafter.com/stuff/2008/09/contours01-300x277.png" alt="" title="contours01" width="300" height="277" class="alignnone size-medium wp-image-620" /></a></p>
<p>At the bottom of the &#8220;Properties&#8221; palette you will find the object data section that looks something like this:</p>
<p><a href="http://www.lazydrafter.com/stuff/2008/09/contours02.png"><img src="http://www.lazydrafter.com/stuff/2008/09/contours02-300x55.png" alt="" title="contours02" width="300" height="55" class="alignnone size-medium wp-image-621" /></a></p>
<p>In this example you would take this expression:</p>
<pre>:[FIELD]@[TABLE]</pre>
<p>&#8230;and replace [FIELD] with ELEV, and replace [TABLE] with Default_contour so it looks like this:</p>
<pre>:ELEV@Default_contour</pre>
<p>Save the file with a .scr extension. Type SCRIPT in AutoCAD to browse for your script file and open it. It will run immediately and you should see your contour data come in on the correct elevations.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.lazydrafter.com/autocad-map-3d-tips/contours-from-shape-files-with-elevations/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Help! RECOVER doesn&#8217;t work.</title>
		<link>http://www.lazydrafter.com/autocad-tips/help-recover-doesnt-work</link>
		<comments>http://www.lazydrafter.com/autocad-tips/help-recover-doesnt-work#comments</comments>
		<pubDate>Thu, 19 Jun 2008 17:14:32 +0000</pubDate>
		<dc:creator>Josh Jones</dc:creator>
				<category><![CDATA[AutoCAD Map 3D Tips]]></category>
		<category><![CDATA[AutoCAD Tips]]></category>
		<category><![CDATA[Troubleshooting]]></category>

		<guid isPermaLink="false">http://www.lazydrafter.com/?p=20</guid>
		<description><![CDATA[Sadly most of us have experienced this kind of frustration. A drawing becomes so corrupted that RECOVER can&#8217;t even fix it. Never fear! Autodesk has workarounds. These tips are good to know because it seems things like this tend to happen when a deadline is right around the corner.]]></description>
			<content:encoded><![CDATA[<p>Sadly most of us have experienced this kind of frustration. A drawing becomes so corrupted that RECOVER can&#8217;t even fix it. Never fear! Autodesk has <a href="http://usa.autodesk.com/adsk/servlet/ps/item?siteID=123112&#038;id=2896262&#038;linkID=9240617">workarounds</a>. These tips are good to know because it seems things like this tend to happen when a deadline is right around the corner.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.lazydrafter.com/autocad-tips/help-recover-doesnt-work/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Civil 3D Inquiry Commands</title>
		<link>http://www.lazydrafter.com/autocad-map-3d-tips/civil-3d-inquiry-commands</link>
		<comments>http://www.lazydrafter.com/autocad-map-3d-tips/civil-3d-inquiry-commands#comments</comments>
		<pubDate>Wed, 04 Jun 2008 19:48:05 +0000</pubDate>
		<dc:creator>Josh Jones</dc:creator>
				<category><![CDATA[AutoCAD Civil 3D Tips]]></category>
		<category><![CDATA[AutoCAD Map 3D Tips]]></category>
		<category><![CDATA[Commands]]></category>

		<guid isPermaLink="false">http://www.lazydrafter.com/?p=15</guid>
		<description><![CDATA[There are some useful inquiry commands in Civil 3D 2008 &#038; 2009. Similar commands used to be available in Map 3D, but from what I hear (and in my experience) they have stopped working. Check out these Civil 3D inquiry commands: CGCLIST &#8211; Lists line and arc information. CGSLIST &#8211; Lists slope information. CGCDIST &#8211; [...]]]></description>
			<content:encoded><![CDATA[<p>There are some useful inquiry commands in Civil 3D 2008 &#038; 2009. Similar commands used to be available in Map 3D, but from what I hear (and in my experience) they have stopped working. <span id="more-15"></span></p>
<p>Check out these Civil 3D inquiry commands:<br />
CGCLIST &#8211; Lists line and arc information.<br />
CGSLIST &#8211; Lists slope information.<br />
CGCDIST &#8211; Measures distance from either a single base point or continuous distances added up.<br />
CGADIST &#8211; Add distances by typing a number, clicking two points, or selecting numeric text.<br />
CGANG &#8211; Returns the angle between two lines.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.lazydrafter.com/autocad-map-3d-tips/civil-3d-inquiry-commands/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Map 3D Drawing Query Macro</title>
		<link>http://www.lazydrafter.com/autocad-map-3d-tips/map-3d-drawing-query-macro</link>
		<comments>http://www.lazydrafter.com/autocad-map-3d-tips/map-3d-drawing-query-macro#comments</comments>
		<pubDate>Mon, 02 Jun 2008 16:41:42 +0000</pubDate>
		<dc:creator>Josh Jones</dc:creator>
				<category><![CDATA[AutoCAD Civil 3D Tips]]></category>
		<category><![CDATA[AutoCAD Map 3D Tips]]></category>
		<category><![CDATA[Macros]]></category>

		<guid isPermaLink="false">http://www.lazydrafter.com/?p=12</guid>
		<description><![CDATA[Have you ever wanted to import just a portion of another drawing into your current drawing? I know the civil engineering world frequently needs to import specific data from one map to another. Since I work in that world and because I&#8217;m lazy, I created a quick method for importing data from standard maps into new [...]]]></description>
			<content:encoded><![CDATA[<p>Have you ever wanted to import just a portion of another drawing into your current drawing? I know the civil engineering world frequently needs to import specific data from one map to another. Since I work in that world and because I&#8217;m lazy, I created a quick method for importing data from standard maps into new drawings using queries and macros. <span id="more-12"></span></p>
<p>If you are at all familiar with creating queries in Map 3D, you already know it is possible to do what I mentioned above. If you are not familiar with queries, simply put, a query is a way to grab entities from another drawing, based on object data and properties, and bring it into your current drawing. In this tip I am not going to get into the details of creating queries, but I am going to show you how to make a simple macro to import everything from one drawing into another, within the area of a rectangle. You need Map 3D or Civil 3D to do this.</p>
<p><a href="http://www.lazydrafter.com/autocad-resources/create-a-custom-toolbar-in-autocad/">Create a button</a>, and add this code to the command macro:</p>
<pre>^C^Ccmddia;0;ZOOM;EXTENTS;ADEDRAWINGS;at;C:/YOUR/DRAWING/PATH/DrawingName.dwg;x;adequery;p;of;x;c;d;l;w;c;\\p;and;la;*;x;e;d;ADEDRAWINGS;de;DrawingName.dwg;x;cmddia;1;REGENALL;</pre>
<p>Replace &#8220;C:/YOUR/DRAWING/PATH/DrawingName.dwg&#8221; with the path to the drawing from which you want to import objects. Be sure to use forward slashes (/). If you use back slashes (\) it will pause the macro for user input.</p>
<p>Also be sure to replace the second &#8220;DrawingName.dwg&#8221; with the name of the same drawing you specified above.</p>
<p>That&#8217;s all there is to it! Click on the button you created, click two points to create a rectangle, and if there are objects in the rectangular area you specified, they will appear in your current drawing.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.lazydrafter.com/autocad-map-3d-tips/map-3d-drawing-query-macro/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Raster Design Object Enabler</title>
		<link>http://www.lazydrafter.com/autocad-map-3d-tips/raster-design-object-enabler</link>
		<comments>http://www.lazydrafter.com/autocad-map-3d-tips/raster-design-object-enabler#comments</comments>
		<pubDate>Fri, 30 May 2008 17:03:35 +0000</pubDate>
		<dc:creator>Josh Jones</dc:creator>
				<category><![CDATA[AutoCAD Civil 3D Tips]]></category>
		<category><![CDATA[AutoCAD Map 3D Tips]]></category>
		<category><![CDATA[Macros]]></category>
		<category><![CDATA[Raster Images]]></category>

		<guid isPermaLink="false">http://www.lazydrafter.com/?p=11</guid>
		<description><![CDATA[I found out that installing Raster Design Object Enabler for Map 3D or Civil 3D allows MrSID images to be inserted directly into AutoCAD through Map 3D&#8217;s image insert command (MAPIINSERT). I use it to directly insert georeferenced ortho photos in MrSID format into my drawings. This is really nice because instead of using another piece [...]]]></description>
			<content:encoded><![CDATA[<p>I found out that installing <a href="http://usa.autodesk.com/adsk/servlet/ps/dl/index?siteID=123112&amp;id=2334440&amp;linkID=9240618">Raster Design Object Enabler</a> for Map 3D or Civil 3D allows MrSID images to be inserted directly into AutoCAD through Map 3D&#8217;s image insert command (MAPIINSERT). I use it to directly insert georeferenced ortho photos in MrSID format into my drawings. This is really nice because instead of using another piece of software to cut out the ortho to insert, I can directly insert the lightweight MrSID image directly and clip it to my desired area. <span id="more-11"></span></p>
<p>I even created a <a href="http://www.lazydrafter.com/autocad-resources/create-a-custom-toolbar-in-autocad/">button with a macro</a> to automate the insertion and clipping of the ortho photo:</p>
<pre>^C^Cfiledia;0;cmddia;0;-LAYER;N;Z_ORTHO;S;Z_ORTHO;C;1;Z_ORTHO;P;N;Z_ORTHO;;MAPIINSERT;S:/DATA/ortho/cortho2005.sid;Y;ZOOM;E;filedia;1;cmddia;1;-LAYER;S;0;;(ssget "x" (list (cons 8 "Z_ORTHO")));DRAWORDER;P;;B;(alert (strcat "Pick 2 points to draw a rectangle in the area you want to show the ortho photo."));IMAGECLIP;P;N;\\^C^CZOOM;E;(alert (strcat "Click on the RED box to make the photo appear. Otherwise hit ESC a few times."));\MAPISHOWIMAGE;</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.lazydrafter.com/autocad-map-3d-tips/raster-design-object-enabler/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

