
! script name: layers.d/layerrange
! topic: ask for a starting/ending layer and set plot layers to all in range

!A
!A NAME:
!A
!A 	Show range of layers
!A
!A DESCRIPTION:
!A
!A	Displays all layers in a given range
!A
!B INSTRUCTIONS:
!B
!B      STARTING LAYER
!B
!B      Enter the start of the range
!B
!B      ENDING LAYER
!B
!B      Enter the end of the range
!B

stat=ChangeLabelStr("ScriptNameStatus","Function: hidelayers")

DIM Layer$[8192]
DIM Active$[8192]
DIM Destination$[256]
DIM Answer$[256]

Stat=SetInputFormat("n0","")
Startlayer=GetValue("STARTING LAYER",Answer$)
IF (ExitScript(Destination$)) THEN Leave
Endlayer=GetValue("ENDING LAYER",Answer$)
IF (ExitScript(Destination$)) THEN Leave
Active$=""
FOR I=Startlayer TO Endlayer+1
Active$=Active$&","&VAL$(I)
NEXT I
Stat=SetPlotLayers(Active$,0)
UpdatePropPlot

Leave:!
IF (NOT LEN(Destination$)) THEN
	 LOAD "typecontrol"
ELSE
	 LOAD Destination$
END IF
END

