[Search tip detail and code files using keywords, tip number, author name, etc ]
 
    For tip to function correctly, you must ensure that the downloaded file name matches the file name
    displayed in the Rename File To field. Please rename downloaded files when necessary.
Offset to Any Layer
Tip# 3707 By Kent Cooper On 16-Aug-2011
0
Rated By 0 users Downloaded : 288
Categories : Object Properties, 2D Editing
Software type : AutoCAD 2012
Rename File To : OffsettoLayer.lsp
Offset to any layer, not just the current one.

Editor's note: This description was updated on August 29, 2011.

There has probably been an Offset to Layer command available since AutoLISP was introduced. Autodesk eventually included this ability into the core Offset command. All these years later, Kent Cooper has still managed to improve on this idea.

This version of Offset to Layer will allow you to offset to any layer, not just the current layer or the source layer. You can even offset objects to locked layers. To get started, load the LSP file and type OL on the Command line. Enter the offset distance (or Through), type in any existing layer name, then finish the command. If you enter a layer that does not exist, you can try again. This routine also remembers the last used distance, separate from the distance last used by the core Offset command.

AutoLISP fans, check out Kent’s code, which is well documented with comments.

 

 

 

Average Rating:
0


User comments