Vooh Posted April 8, 2009 Posted April 8, 2009 Heya folks. I'm having a bit of trouble with my 2d drawings, and I was hoping someone could help out an autocad newbie. I'm trying to find a way to automatically sort the order that lines appear on my drawing. Meaning that I want my Object Lines layer to always be on top, with my hidden lines layer to be second on top, centrelines third on top etc etc... I've dabbled around with Draworder, but I've got some pretty big drawings and it would take a long time to go about it. Any help or advice you can give would be greatly appreciated! Quote
stevsmith Posted April 8, 2009 Posted April 8, 2009 ;; Moves all objects on the "object" layer to the front (defun c:lf() ;; creates a selection set of all objects on the "object" layer. (setq sel1 (ssget "x" '((8 . "0")))) ;; Uses the draworder command to move the objects to the front (command "draworder" sel1 "" "front") ) Courtacy of LeeMac.... You can use this and edit to suit. Quote
Vooh Posted April 8, 2009 Author Posted April 8, 2009 Sorry for my ignorance mate, but how do I go about using the code? Do I just copy/paste it into autocad? Quote
ReMark Posted April 8, 2009 Posted April 8, 2009 It's a Lisp routine. Please refer to the AutoCAD FAQ section of CADTutor. Look under Customisation. The topic header is "How do I use an AutoLisp routine?" Quote
Tiger Posted April 8, 2009 Posted April 8, 2009 For the lazy ones: How do I use a LISP routine. Quote
fuccaro Posted April 8, 2009 Posted April 8, 2009 If someone wishes to try it first: select the code, copy it in the clipboard (CTRL+C), click in AutoCAD command line and paste the text (CTRL+V). AutoCAD should report that LF is loaded. So type LF in the command line to start the routine. This way the program loads only in the current drawing session -meaning that you must reload it each time you wish to use it in other drawings- or even in the current one after you close/reopen it Quote
GE13579 Posted April 8, 2009 Posted April 8, 2009 Another command you might find useful for this and for future requirements is QSELECT. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.