Restores a group of layer property settings.
Supported platforms: Windows only
VBA:
object.Restore Name
Type: LayerStateManager
The object this method applies to.
Access: Input-only
Type: String
The name of the saved layer settings to be restored.
No return value.
The Restore method uses the Mask property associated with the saved settings to identify which layer properties are to be restored.
VBA:
Sub Example_RestoreLayerSettings() ' The following code restores color and linetype settings ' that were saved as "ColorLineType". Dim oLSM As AcadLayerStateManager Set oLSM = ThisDrawing.Application. _ GetInterfaceObject("AutoCAD.AcadLayerStateManager.20") oLSM.SetDatabase ThisDrawing.Database oLSM.Restore "ColorLinetype" End Sub
Visual LISP:
(defun c:Example_Restore() ;; The following code restores color and linetype settings ;; that were saved as "ColorLineType." (setq acadObj (vlax-get-acad-object)) (setq doc (vla-get-ActiveDocument acadObj)) ;; Access the LayerStateManager object. (setq oLSM (vla-GetInterfaceObject acadObj "AutoCAD.AcadLayerStateManager.20")) (vla-SetDatabase oLSM (vla-get-Database doc)) (vla-Restore oLSM "ColorLinetype") )