Home Product Purchase Support Testimonials Contact

CADSTA Tools - LayerState-GetLayers/Restore

layerstate-getlayers

Returns the layers saved in a layer state.

(layerstate-getlayers layerstatename [invert])

Arguments

layerstatename

Type: String

Name of the layer state.

invert

Type: T, nil or omitted

T

The layers in the returned list are not saved in the layer state.

nil or omitted

The layers in the returned list are saved in the layer states.

Return Value

List or nil.

Examples

_$ (layerstate-getlayers "myLayerState")

("Roofs" "Windows")

layerstate-restore

Restores a layer state into the current drawing.

(layerstate-restore layerstatename viewport [restoreflags])

Arguments

layerstatename

Type: String

Name of the layer state to be checked.

viewport

Type: ads_name

An ename of the viewport to which layerstatename will be restored. If viewport is nil, the layer state is restored to model space.

restoreflags

Type: Integer

Optional value affecting how the layer state is restored.

1

Turns off the layer

2

Freezes the layer

4

Locks the layer

Return Value

List or nil.

Examples

_$ (layerstate-restore "myLayerState" viewportId 5)

("Site Plan" "Electrical")

Related References

layerstate-compare

layerstate-getnames

layerstate-rename

layerstate-delete

layerstate-has

layerstate-save

layerstate-export

layerstate-import

layerstate-getlastrestored

layerstate-importfromdb

layerstate-addlayers

layerstate-removelayers

Try or Buy

Product Information

CADSTA Tools

CADSTA Tools Features

Using AutoLISP with CADSTA Tools

Supported AutoLISP file format

Enter AutoLISP codes at command Line

Using AutoLISP with Menu

Using MNL file with CADSTA Tools

Appload Command

CADSTATools.lsp / acad.lsp

CADSTAToolsDoc.lsp / acaddoc.lsp

S::STARTUP Function

Startup Suite

LISP Functions: Operators

LISP Functions: A - C

LISP Functions: D - H
LISP Functions: I - P
LISP Functiosns: Q - U

LISP Functions: V

LISP Functions: W - Z

CADSTA Elements Features

Forum

Click here to go to our forum where you can exchange information, ask questions and share tips with others.

Search

Enter search words

Sign Up For Newsletter

Click here to sign up for our newsletter.

Follow Us