Easily Create a Drawing List

This tip was tested and works with Windows Explorer and Google Chrome (and Microsoft Excel…)

To create a list of drawings, either for yourself or for a client, these steps can help save some time.

  • Navigate to the folder in Windows Explorer
  • Copy the folder location

Drawing List 1

 

  • Paste the folder location into Google Chrome and press enter
  • Note: I have not tried this with Firefox. I did try it with Internet Explorer and when I hit enter, it would open the folder location…

Drawing List 2

 

  • Highlight the files as they are displayed in the browser and copy

Drawing List 3

 

  • Paste the copied list of files into Excel in the upper left corner.

Note 1: After the initial spread sheet is created, you can add to this list by adding to the bottom row of the spreadsheet.

Note 2: You have 2 choices when Pasting the content

Drawing List 4

 

  • “Keep Source Formatting” will also create a link to the individual files (could be handy)

Drawing List 5

 

  • “Match Existing Formatting” will keep the formatting as simple text

Drawing List 6

 

After pasting the content into Excel, you may need to clean up some columns and rows… But this will save some time instead of manually creating a drawing list.

~enjoy

Posted in Manage, TIPS | 3 Comments

AutoLISP: Simple Numeric Array

Today’s featured routine is an example from a book about Visual Lisp Programming and was an example that we learned from as an example in class when I was in school.

It is a simple routine that lets you incrementally array a row of numbers. This might be helpful for creating numbered lists or placing numbers along a line…

Lee-Mac has made some pretty powerful numbering routines that can do a lot more than this routine does. These routines can be found here:

http://lee-mac.com/incrementalarray.html

http://lee-mac.com/numinc.html

Here’s how:

  • NUMROW <enter>
  • Specify the first text location – this will be # zero
  • Specify the distance – either by picking 2 points on screen or by entering the distance in the command line
  • Specify the angle – either by picking 2 points on screen or by entering the angle in the command line ACAD Angle
  • Specify the ending number of the array

~enjoy

NumRow


; Example from book: Visual Lisp Programming
; NumRow.lsp by Cal Clater
;
; 1/12/xx
;
; Purpose: To create an evenly spaced row of incrementally increasing numbers,
; such as might be required for a chart or graph. The beginning number is zero
; and the last number is as specified.
;
(defun C:NumRow (/ PT1 DST DIR NN HN)
    (setvar "CMDECHO" 0) (setvar "BLIPMODE" 0)
    (princ "\nText will be center justified.")
    (setq PT1 (getpoint "\nstart point of number row: ")
          DST (getdist "\nDistance between number: ")
          DIR (getorient "\nAngle: ")
          NN 0
          HN (getint "\nNumber sequence to be 0 through: ")
    )
    (command "TEXT" "C" PT1 "" "" "0")
    (repeat HN
      (setq PT1 (polar PT1 DIR DST))
      (command "TEXT" "C" PT1 "" "" (itoa (setq NN (+ NN 1))))
    )
)
Posted in AutoLISP, AutoLISP: Creating, AutoLISP: Text, Uncategorized | 2 Comments

AutoLISP: Fillet and Match PLINE Width

With the release of AutoCAD 2012 the JOIN command received some improvements. It will join all of the selected objects regardless of what type of objects they are (line, arc, polyline, 3Dpolyline, spline) and turn them into the most complicated object in the selection set. Because of this enhancement of the JOIN command, it appears that Autodesk took away a useful feature from the FILLET command. The missing feature that many are used to seeing is when you fillet a polyline that has  a width applied to it, the other objects would inherit the width of the polyline. This is no longer the case with the FILLET command in 2012 and 2013.

Luckily I found this routine that lets you FILLET objects just like before…

originally found here: http://forums.autodesk.com/t5/Visual-LISP-AutoLISP-and-General/Join-then-fillet-polylines/m-p/811123/highlight/true#M36781

Fillet Behavior introduced in AutoCAD 2012:

Fillet 2012Fillet behavior prior to 2012 and that the lisp routine provides:

My Fillet New

fillet-new-1

 


;;; MY-FILLET.LSP Fillet PolyLines
;;; Fillets Any Type of Line (Line, PolyLine, LWPolyLine or Spline)
;;; by Ibro Vehabovic, March 1999.
;;; http://forums.autodesk.com/t5/Visual-LISP-AutoLISP-and-General/Join-then-fillet-polylines/td-p/.UNyL7-SLlyI

(defun c:my-fillet (/ getval spl2pl e1 e2 p2 l e ss)

;;; GETVAL - returns the group value of an entity.
;;; like the wellknown (dxf) function but accepts all kinds of
;;; entity representations (ename, entget list, entsel list)
  (defun GETVAL	(grp ele)		;"dxf value" of any ent...
    (cond ((= (type ele) 'ENAME)	;ENAME
	   (cdr (assoc grp (entget ele)))
	  )
	  ((not ele) nil)		;empty value
	  ((not (listp ele)) nil)	;invalid ele
	  ((= (type (car ele)) 'ENAME)	;entsel-list
	   (cdr (assoc grp (entget (car ele))))
	  )
	  (T (cdr (assoc grp ele)))
    )
  )					;entget-list

;;; "converts" SPLINE to PLINE
  (defun spl2pl	(ent / osm pdm deltaL pn pts e)
    (setq osm (getvar "OSMODE"))
    (setq pdm (getvar "PDMODE"))
    (setvar "OSMODE" 0)
    (setvar "PDMODE" 0)
    (setq
      deltaL (*	(/ (GETVAR "viewsize") (CADR (GETVAR "screensize")))
		(getvar "pickbox")
		2.0
	     )
    )					; max segment=2 * size of
    pickbox
    (if	(= (getval 0 ent) "POLYLINE")	; heavy pline
      (progn
	(setq e ent)
	(while (= (getval 0 (setq e (entnext e))) "VERTEX")
	  (setq pts (cons (getval 10 e) pts))
	)
	(setq pn  (car pts)
	      pts (list (last pts))
	)
      )
      (setq pts	(list (getval 10 ent))	; start pt
	    pn	(getval 10 (reverse (entget ent)))
      )
    )					; end pt
    (command ".POINT" pn)
    (setq e (entlast))
    (entdel e)
    (command ".AREA" "_O" ent)
    (command ".DIVIDE"
	     ent
	     (fix (/ (getvar "perimeter") deltaL))
    )
    (while (setq e (entnext e))
      (setq pts (cons (getval 10 e) pts))
      (entdel e)
    )
    (setq pts (reverse (cons pn pts)))
    (apply 'command (append '(".PLINE") pts '("")))
    (command ".CHANGE"
	     (entlast)
	     ""
	     "_P"
	     "_LA"
	     (getval 8 ent)
	     ""
    )
    (if	(getval 62 ent)
      (command ".CHANGE"
	       (entlast)
	       ""
	       "_P"
	       "_C"
	       (getval 62 ent)
	       ""
      )
    )
    (entdel ent)
    (setvar "PDMODE" pdm)
    (setvar "OSMODE" osm)
    (entlast)
  )					;defun spl2pl

  (setvar "cmdecho" 0)
  (command "._UNDO" "_BE")
  (while (null (setq e1 (entsel "\nSelect first object: "))))
  (if (= (getval 0 e1) "SPLINE")
    (setq e1 (list (spl2pl (car e1)) (cadr e1)))
  )
  (if (= (getval 0 e1) "POLYLINE")
    (if	(> (getval 70 e1) 1)
      (setq e1 (list (spl2pl (car e1)) (cadr e1))) ;fit or spline
      (command ".CONVERTPOLY" "_L" (car e1) "")
    )
  )					;heavy pline
  (redraw (car e1) 3)
  (while (null (setq e2 (entsel "\nSelect second object: "))))
  (if (= (getval 0 e2) "SPLINE")
    (setq e2 (list (spl2pl (car e2)) (cadr e2)))
  )
  (if (= (getval 0 e2) "POLYLINE")
    (if	(> (getval 70 e2) 1)
      (setq e2 (list (spl2pl (car e2)) (cadr e2))) ;fit or spline
      (command ".CONVERTPOLY" "_L" (car e2) "")
    )
  )					;heavy pline
  (redraw (car e2) 3)
  (setq p2 (cadr e2))
  (setq e2 (car e2))
  (if (and (= (getval 0 e1) "LWPOLYLINE")
	   (= (getval 0 e2) "LWPOLYLINE")
      )
    (progn
      (setq l (entlast))
      (command ".EXPLODE" e2)
      (setq ss (ssadd))
      (ssadd (setq e (entnext l)) ss)
      (while (setq e (entnext e))
	(ssadd e ss)
      )
      (command ".FILLET" e1 (nentselp p2))
      (command ".PEDIT" e1 "_J" ss "" "") ; join
      (command ".ERASE" ss "")		; erase unjoined segments
					; of the second polyline
    )					;progn
    (command ".FILLET" e1 (nentselp p2)) ;normal fillet
  )					;if
  (command "._UNDO" "_E")
  (princ)
)					;defun
Posted in AutoCAD 2013, AutoLISP, AutoLISP: Modify, AutoLISP: Polylines, Modifying, New in 2012, New In 2013, Polylines | 4 Comments

Set the Options Dialog to Specific Tab

Here is a quickie.

You can use this as a script or macro for a custom tool…

If you go to the OPTIONS dialog box often, you may want to open on a specific tab for whatever task you are doing.

Here’s how:

  • +OPTIONS <enter>
  • The default is <0> (zero) and if you simply hit <enter> again it will open the last tab that you were on. So if I want the Options dialog to open on the “Files” tab I would enter the following at the command line:
      1. +OPTIONS <enter>
      2. 0 <enter> (zero)

The thing to remember about this tip is to use the + (plus sign) at the beginning of the command….

Refer to the picture below that shows what tabs equal what number equals what tab.
Note that the Options dialog box shown below is from AutoCAD 2013

Options

(See below for the many ways to open the OPTIONS dialog “the normal way”)

  • Right-click anywhere in the drawing area and select “Options”

Options 1

  • Click on the Application Menu (Big Red A)
  • Then click Options at the bottom of the menu

Options 2

  • Type in either OP <enter> or OPTIONS <enter> in the command line

Options 3

Posted in Customization, Manage, TIPS | 3 Comments

Pre Selection Highlight

Here is how to change the setting that allows you to highlighting objects prior to selection. This feature is useful so that you can visibly see what you are about to select prior to actually selecting them.

OPTIONS <enter> or OP <enter>

Make the “Selection” tab current

To turn this feature on, make sure that the check marks are checked under the “Selection Preview” area  of the “Selection” tab (orange area shown below)

In the “Visual Effect Settings” dialog, you can define how the pre-highlighting is displayed: 1) Dashed lines, 2) Bold, 3) Both (the default = both)

Pre Selection Highlight

 

The Advanced options button will display a little dialog box that shows what items are excluded from being pre-highlighted

Prehighlighting 3

 

Shown below – hovering the cursor over objects with pre-selection highlighting turned OFF

Prehighlighting 1 OFF

 

Shown below – hovering the cursor over objects with pre-selection highlighting turned ON

Prehighlighting 2 ON

Posted in Customization, Manage, Settling In, TIPS | 4 Comments

How to show hidden folders

This might seem like an odd post but it is helpful because there is an AutoCAD support path that might be hidden thus preventing you from navigating to this location through Windows Explorer.

The desired support location is located within the “AppData” folder. This folder is unique for each user for a computer. The location is C:\Users\UserName\AppData\Roaming\Autodesk\AutoCAD 2013 – English\R19.0\enu\Support

If you navigate to C:\Users\Username folder you may not see the folder called “AppData”

(Note: My username folder is called “Trog”)

Hidden Files 1

  • If you press the ALT button you will see the below menus appear.
  • Click the tools button from the menu and then click “folder options”

Hidden Files 2

 

Click the “View” tab to make it active

  • Then scroll down and click to toggle to “Show hidden files, folders and drives”
  • This menu is also where you can change how the file types are shown, A file type is the three-letter file extension that is at the end of a file name. For example, a .dwg is an AutoCAD drawing file. Or a .pdf file is a PDF file…

Hidden Files 3

 

 

Click OK when you are finished.

You should know see the below folder “AppData”

Hidden Files 4

Posted in BASICS, Manage | Leave a comment

2013 Command Line Width

I really like how little space the new command line takes up in the drawing area (vertically), but did you know that the new command can be sized horizontally?

Simple move your cursor over the right edge to the command line and then click, hold and drag to re-size its width. Now it takes up even less room!!!

(Note that it stretches/shrinks about its mid point)

Posted in AutoCAD 2013, BASICS, Customization, New In 2013, Settling In, Tool Palletes | 2 Comments