
! script name: misc.d/test

!A
!A NAME:
!A
!A 	test
!A
!A DESCRIPTION:
!A
!A 	NO HELP AVAILABLE AT THIS TIME
!A
!B INSTRUCTIONS:
!B
!B 	questions with brief description
!B
!B OPTIONS:
!B 	
!B

OPTION BASE 1
stat=ChangeLabelStr("ScriptNameStatus","Function: test ")

DIM Destination$[256]
DIM Answer$[256]
DIM Name$[256]
DIM Question1$[180]
DIM Question$(10)[80],Reply$(10)[80]

Start:!

Question1$="Type number, Starting X, Starting Y, Ending X, Ending Y, Radius 1, Radius 2, Radius 3"

Question$(1)="Type number"
Question$(2)="Starting X"
Question$(3)="Starting Y"
Question$(4)="Ending X"
Question$(5)="Ending Y"
Question$(6)="Radius 1"
Question$(7)="Radius 2"
Question$(8)="Radius 3"

Reply$(1)="4"
Reply$(2)="1.2"
Reply$(3)="3.4"
Reply$(4)="5.6"
Reply$(5)="7.8"
Reply$(6)="0.8"
Reply$(7)="9.8"
Reply$(8)="0.75"

REPEAT

Stat=ChangeLabelStr("MultiLineShell","Type 4 Input")
ApplyLoop: !
Stat=MultiInput(Question$(*),Reply$(*),1)
PRINT Stat

IF (ExitScript(Destination$)) THEN Leave
! IF Stat > 0 then user has cancelled the input
IF Stat>2 THEN Leave

FOR I=1 TO 8
PRINT "Reply$( ";i;") = ";Reply$(i)
NEXT I
IF Stat=1 THEN ApplyLoop

!
! Type4(4,Xs,Ys,Xe,Ye,R1,R2,R3)
!
Tp=Type4(VAL(Reply$(1)),VAL(Reply$(2)),VAL(Reply$(3)),VAL(Reply$(4)),VAL(Reply$(5)),VAL(Reply$(6)),VAL(Reply$(7)),VAL(Reply$(8)))
IF (NOT ValidGeometry(Tp)) THEN Leave

UNTIL ValidGeometry(Tp)

Leave:!

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