Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations cowski on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Lisp for translating the layers

Status
Not open for further replies.

Histor

Electrical
Joined
Mar 2, 2022
Messages
70
Location
SG
I have a drawing exported from 3D to 2D. In AutoCAD 2D Drawing all the layers needs to be laytransed to background layer (grey).

when I do laytrans, Some of the layers (LayerA and layerC), shall be excluded from above mentioned laytrans.

I am manually doing the laytrans. But I want some one of your help to get lisp for performing this activity.
 
A "script" (*.scr file) could probably handle this, depending on your layer naming convention.
Here's one site with info:
The script file would look something like:

layer
color
8 (or other background color)
*
color
(desired color here)
LayerA,layerc
(2 blank lines, to end the layer command)


Or if excluded layers should just keep original color, maybe this:

layer
lock
LayerA,layerc
color
8
*
unlock
LayerA,layerc
(2 blank lines, to end the layer command)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top