Search the Community
Showing results for tags 'layerstatesave'.
andre81 posted a topic in AutoLISP, Visual LISP & DCLHi All, I'm Autolisp beginer and first problem which I would like to solve with it is how to restore layers Visibility after Layiso command. In few steps it's looks like: 1. Before use Layiso command I'have some layers that are on others are off. 2. I'm using Layiso and makes some changes on drawning. 3. After changing I want to restor layers visibility from point 1 (before Laiso command). My idea is to use LayerState functions: layerstate-save, layerstate-delete and layerstate-restore. I have problem with using LayerState functions. I could name functions for example "Iso" and "RestoreState". LayerState name could be "XX" Program structure: Step 1 - c:Iso I'm checking if "XX" exist. If "XX" exist then using layerstate-delete I'm deleting "XX". I'm creating LayerState "XX" using layerstate-save. Step 2 (command "Layiso") Step 3 I'm doing some changes in drawing. Step 4 - c:RestoreState I'm restoring "XX" using layerstate-restore. My problem is that I don't know how to use LayerState functions. Many info I've found here: http://www.cadtutor.net/forum/showthread.php?39986-LayerState-Manipulation-Info.-Coding but still don't know how to for example make Layerstate "XX" using it. or don't work. How it should look like? Also I've tried to use only commands: This code don't has checking if "XX" exist but works. How to write code using LayerState functions?? Anyone can help? Sorry for my English