 /*
 *	FILE:
 *		DataCAD 5.02
 *
 */

@DefineProject
	@Name 		= "DataCAD" 
	@Version	= "5.02"
	@Subdir 	= "\\DCAD5\\"
	@OutDrive 	= C
	@Requires         @HardDisk
	@InDiskBell	= 1
        @Immediate      = 1
@EndProject

@Display
   @Cls

   @If (@CPU < 386)

            @Name requires an 80386 or 80486 CPU.
            Your computer is running on a 80@CPU CPU.

   @Pause

   @Exit

   @EndIf

@EndDisplay      

@If (@VideoCard == 'V')
   @If (@RAMAvail > 529000)
      @If (@System ("@StartupDrive:\\gifview @StartupDrive:\\intro.gif"))
      @EndIf
   @EndIf
@EndIf

@Display
   @Cls



                       Cadkey - Installation Utility        
                


                               Cadkey, Inc.                
                        Windsor, Connecticut (USA)        
                         Copyright (c) 1984-1993           
                           All rights reserved            
                 




   @Pause


	@Cls

    This program installs @Name Version @Version on 
    your computer system and verifies the integrity of the distribution 
    files. It asks you several questions about your computer 
    hardware and then gives you the option of installing only selected 
    parts of @Name (such as the DataCAD Program). 

	@Pause
@EndDisplay

@DefineVars
	@Dir		@Subdir2	= "\\DCAL\\"    
	@Dir		@Subdir3	= "\\VELOCITY\\"
	@Drive		@OutDrive2	= C
	@Drive		@OutDrive3	= C
@EndVars

@SetGroup(A)

regroup:

@GetGroups
	@Checkbox
	@Cls

	Now you need to select the parts of @Name you want to install.















	Use the [Up Arrow], [Down Arrow], [PgUp], & [PgDn] keys to move the
	bar to the group(s) you wish to install and then press the [Space] key
	to toggle the option from "No" to "Yes".  Press [Enter] when you
	have selected the option(s) you want to install.
	@SET A = "Install All files - 34.1M Bytes"
	@SET D = "Install DataCAD - 6.5M Bytes"
	@SET H = "Install DataCAD Online Documentation - 3.4M Bytes"
	@SET C = "Install DCAL - 2.1M Bytes"
	@SET V = "Install DataCAD Velocity - 3.2M Bytes"
	@SET P = "Install DataCAD Printer Utility - 393K Bytes"
	@SET E = "Install Symbol Libraries - 17.7M Bytes"
	@SET U = "Install DataCAD Graphics Driver(s)"

@EndGroups
@GetOption
@If ('A'[=@Group || 'D'[= @Group || 'C'[=@Group || 'V'[=@Group || 
     'H'[=@Group || 'P' [= @Group || 'E'[=@Group || 'U'[=@Group	)
                        You will be installing:
	                   @If ( 'A' [= @Group )
                           DataCAD Program files
                           DataCAD Online Documentation
                           DataCAD Velocity files
                           DCAL files
                           DataCAD Printer Utility
                           DataCAD Symbol Libraries
                           DataCAD Graphics Driver           @EndIf  @If ( 'D' [= @Group )
                           DataCAD Program files             @EndIf  @If ( 'H' [= @Group )
                           DataCAD Online Documentation      @EndIf  @If ( 'V' [= @Group )
                           DataCAD Velocity files            @EndIf  @If ( 'C' [= @Group )
                           DCAL files                        @EndIf  @If ( 'P' [= @Group )
                           DataCAD Printer Utility           @EndIf  @If ( 'E' [= @Group )
                           DataCAD Symbol Libraries          @EndIf  @If ( 'U' [= @Group )
                           DataCAD Graphics Driver           @EndIf
@SetOption (4000)
@Else
        No files were selected to be installed.  
@EndIf
@Checkbox
@Option 4000 = "Is this correct ? "
@LocalWindow (21, 35)
      Use the space bar to toggle between "Yes" and "No".
@EndOption

@If (!(4000 [= @Option ))

	@FlushGroups
	@Goto regroup

@EndIf

@If(!('A'[=@Group || 'D'[= @Group || 'H'[= @Group || 'P'[=@Group || 'C'[=@Group || 
   'V'[=@Group    || 'E'[= @Group || 'U'[= @Group ))
@Display
    You must use the space bar to select files to be installed.  The files
    you have selected will have a "Yes" next to them.  Then press the 
    <Enter> key to begin installation.

    You may press the <Esc> key to abort installation.

	@Pause

@EndDisplay

	@Goto regroup

@EndIf

@IF ( 'A' [= @Group )
	@SetGroup( D)
	@SetGroup( H)
	@SetGroup( V)
	@SetGroup( C)
	@SetGroup( P)
	@SetGroup( E)
@EndIf

redo:

@If ('D' [= @Group)

@GetOutDrive

	@Suppress A    /* don't display A:  */
	@Suppress B    /* or B:             */

	@Cls

 	      Choose the drive on which you want to install @Name.















	Use the <Up Arrow>, <Down Arrow>, <PgUp>, & <PgDn> to move the light-
	bar to the disk drive on which you want to install and then press the
	<Enter> key.
@EndOutDrive

retry:

@GetSubdir
	@Cls

	Enter the name you want for your @Name subdirectory. This
	subdirectory is the location on your disk where	DataCAD will reside.

	@Prompt = " Which subdirectory ([Enter] = @Subdir)? "
@EndSubdir


@EndIf

@If ('C' [= @Group)

@GetOutDrive @OutDrive2

	@Suppress A    /* don't display A:  */
	@Suppress B    /* or B:             */

	@Cls

 	      Choose the drive on which you want to install DCAL.















   Use the <Up Arrow>, <Down Arrow>, <PgUp>, & <PgDn> to move the light-
   bar to the disk drive on which you want to install and then press the
   <Enter> key.
@EndOutDrive

retry:

@GetSubdir @SubDir2
	@Cls

   Enter the name you want for your DCAL subdirectory. This
   subdirectory is the location on your disk where DCAL 
   will reside.

	@Prompt = " Which subdirectory ([Enter] = @Subdir2)? "
@EndSubdir

	

@EndIf

@If ('V' [= @Group)

@GetOutDrive @OutDrive3

	@Suppress A    /* don't display A:  */
	@Suppress B    /* or B:             */

	@Cls

       Choose the drive on which you want to install DataCAD Velocity.















   Use the <Up Arrow>, <Down Arrow>, <PgUp>, & <PgDn> to move the light-
   bar to the disk drive on which you want to install and then press the
   <Enter> key.
@EndOutDrive

@GetSubdir @Subdir3
	@Cls

   Enter the name you want for your Velocity subdirectory. This
   subdirectory is the location on your disk where DataCAD Velocity
   will reside.

	@Prompt = " Which subdirectory ([Enter] = @Subdir3)? "
@EndSubdir
@If (!('D' [= @Group))

        @GetOutDrive
                @Suppress A
                @Suppress B

                @Cls
        
        Choose the drive on which @Name version @version is installed.















   Use the <Up Arrow>, <Down Arrow>, <PgUp>, & <PgDn> to move the light-
   bar to the disk drive on which you want to install and then press the
   <Enter> key.
        @EndOutDrive

        @GetSubdir
                @Cls
        Enter the path for your @Name version @version subdirectory.

        @Prompt = " Which subdirectory ([Enter] = @Subdir)?"

        @EndSubDir

   @EndIf

   @GetOption
   @CLS
   


   @SetOption (100)


   @Checkbox


   @Option 100 = "Does your system have expanded memory (EMS) installed?"



              
   
   
   @MoveCStr(10,15,,"Use the space bar to toggle between Yes and No.")

   @EndOption

   @If (!(100 [= @Option))

       @SetOption (110)

   @EndIf

@EndIF

@If (('P' [= @Group)&&(!('D' [= @Group))&&(!('V' [= @Group)))

     @GetOutDrive
                @Suppress A
                @Suppress B

                @Cls
        
        Choose the drive on which @Name version @version is installed.
















   Use the <Up Arrow>, <Down Arrow>, <PgUp>, & <PgDn> to move the light-
   bar to the disk drive on which you want to install and then press the
   <Enter> key.
        @EndOutDrive

        @GetSubdir
                @Cls
        Enter the path for your @Name version @version subdirectory.

        @Prompt = " Which subdirectory ([Enter] = @Subdir)?"

        @EndSubDir

@EndIf   
@If (('H' [= @Group)&&(!('D' [= @Group))&&(!('V' [= @Group))
    &&(!('P' [= @Group)))

     @GetOutDrive
                @Suppress A
                @Suppress B

                @Cls
        
        Choose the drive on which @Name version @version is installed.
















   Use the <Up Arrow>, <Down Arrow>, <PgUp>, & <PgDn> to move the light-
   bar to the disk drive on which you want to install and then press the
   <Enter> key.
        @EndOutDrive

        @GetSubdir
                @Cls
        Enter the path for your @Name version @version subdirectory.

        @Prompt = " Which subdirectory ([Enter] = @Subdir)?"

        @EndSubDir

@EndIf   
@If (('E' [= @Group)&&(!('D' [= @Group))&&(!('V' [= @Group))
    &&(!('P' [= @Group))&&(!('H' [= @Group)))

     @GetOutDrive
                @Suppress A
                @Suppress B

                @Cls
        
        Choose the drive on which @Name version @version is installed.
















   Use the <Up Arrow>, <Down Arrow>, <PgUp>, & <PgDn> to move the light-
   bar to the disk drive on which you want to install and then press the
   <Enter> key.
        @EndOutDrive
        @GetSubdir
                @Cls
        Enter the path for your @Name version @version subdirectory.

        @Prompt = " Which subdirectory ([Enter] = @Subdir)?"

        @EndSubDir

@EndIf   
@If (('U' [= @Group)&&(!('D' [= @Group))&&(!('V' [= @Group))
    &&(!('P' [= @Group))&&(!('H' [= @Group))&&(!('E' [= @Group)))

     @GetOutDrive
                @Suppress A
                @Suppress B

                @Cls
        
        Choose the drive on which @Name version @version is installed.
















   Use the <Up Arrow>, <Down Arrow>, <PgUp>, & <PgDn> to move the light-
   bar to the disk drive on which you want to install and then press the
   <Enter> key.
        @EndOutDrive
        @GetSubdir
                @Cls
        Enter the path for your @Name version @version subdirectory.

        @Prompt = " Which subdirectory ([Enter] = @Subdir)?"

        @EndSubDir

@EndIf   
@GetOption
@CLS @If ('D' [= @Group) 
                   @If (@Exists "@OutDrive:@SubDir") DatCAD will be installed in 
                    the existing directory @OutDrive:@Subdir 
                   @Else DataCAD will be installed in 
                    @OutDrive:@Subdir
	           @EndIf @EndIf @If ('C' [= @Group)
                   @If (@Exists "@OutDrive2:@SubDir2") DCAL will be installed in 
                    the existing directory @OutDrive2:@Subdir2 
                   @Else DCAL will be installed in 
                    @OutDrive2:@Subdir2
	           @EndIf @EndIf @If ('V' [= @Group)
                   @If (@Exists "@OutDrive3:@SubDir3") DataCAD Velocity will be installed in 
                    the existing directory @OutDrive3:@Subdir3 
                   @Else DataCAD Velocity will be installed in 
                    @OutDrive3:@Subdir3
	           @EndIf @EndIf @If ('P' [= @Group)
                   @If (@Exists "@OutDrive:@SubDir") DataCAD Printer Utility will be installed in 
                    the existing directory @OutDrive:@Subdir 
                   @Else DataCAD Printer Utility will be installed in 
                    @OutDrive:@Subdir
	           @EndIf @EndIf @If ('E' [= @Group)
                   @If (@Exists "@OutDrive:@SubDir") Symbol Libraries will be installed in 
                    the existing directory @OutDrive:@Subdir 
                   @Else Symbol Libraries will be installed in 
                    @OutDrive:@Subdir
	           @EndIf @EndIf @If ('H' [= @Group)
                   @If (@Exists "@OutDrive:@SubDir") DataCAD Online Documentation will be installed in 
                    the existing directory @OutDrive:@Subdir 
                   @Else DataCAD Online Documentation will be installed in 
                    @OutDrive:@Subdir
	           @EndIf @EndIf @If ('U' [= @Group)
                   @If (@Exists "@OutDrive:@SubDir") DataCAD Graphics Driver(s) will be installed in 
                    the existing directory @OutDrive:@Subdir\DRV
                   @Else DataCAD Graphics Driver(s) will be installed in 
                    @OutDrive:@Subdir\DRV
	           @EndIf @EndIf
        
        
        @SetOption(3000) @Checkbox @Option 3000 = "Is this correct ?"
	@LocalWindow(20,38) /*@LocalWindow(19,35)*/
        @MoveCStr(21,15,,"Use the space bar to toggle between Yes and No.") @EndOption

@If (!(3000 [= @Option))

	@Goto redo

@EndIf

@If ('A'[=@Group || 'D'[= @Group || 'U'[= @Group )

@ClearOption ( 1)
@ClearOption ( 2)
@ClearOption ( 3)
@ClearOption ( 4)
@ClearOption ( 5)
@ClearOption ( 6)
@ClearOption ( 7)
@ClearOption ( 8)
@ClearOption ( 9)
@ClearOption ( 0)
@ClearOption (11)
@ClearOption (12)
@ClearOption (13)
@ClearOption (14)
@ClearOption (15)
@ClearOption (16)
@ClearOption (17)
@ClearOption (18)
@ClearOption (19)
@ClearOption (20)
@ClearOption (21)
@ClearOption (22)
@ClearOption (23)
@ClearOption (24)
@ClearOption (25)
@ClearOption (26)
@ClearOption (27)
@ClearOption (28)
@ClearOption (29)
@ClearOption (30)
@ClearOption (31)
@ClearOption (32)
@ClearOption (33)
@ClearOption (34)
@ClearOption (35)
@ClearOption (36)
@ClearOption (37)
@ClearOption (38)
@ClearOption (39)
@ClearOption (40)
@ClearOption (41)
@ClearOption (42)
@ClearOption (43)
@ClearOption (44)
@ClearOption (45)
@ClearOption (46)
@ClearOption (47)
@ClearOption (48)
@ClearOption (49)
@ClearOption (50)
@ClearOption (51)
@ClearOption (52)
@ClearOption (53)
@ClearOption (54)
@ClearOption (55)
@ClearOption (56)
@ClearOption (57)
@ClearOption (58)
@ClearOption (59)
@ClearOption (60)
@ClearOption (61)
@ClearOption (62)
@ClearOption (63)
@ClearOption (64)
@ClearOption (65)
@ClearOption (66)
@ClearOption (67)
@ClearOption (68)
@ClearOption (69)
@ClearOption (70)
@ClearOption (71)

driver:

@GetOption
       @CheckBox


@cls              Please select one or more of the graphic drivers.
              Use the space bar to toggle between "Yes" and "No".
      Press Y to select all drivers.  Press N to deselect all drivers.















             Use the <Up Arrow> and <Down Arrow> keys to move the  
             lightbar to the graphics driver you want to select.
                     <Enter> downloads selected drivers.

      @option  2 = "ATC Graphics 8514/A"		     /* ATC8514.EXE */
      @option  5 = "ATI VGA Wonder 256 color"		     /* ATIV256.EXE */
      @option  9 = "Compaq Portable Plasma Display"	     /* CPAQ.EXE */
      @option 10 = "Compaq Advanced Graphics 1024"	     /* CKDGIS.EXE */
      @option 13 = "DGIS compatibles"			     /* CKDGIS.EXE */
      @option 22 = "HP Intelligent Graphic Controller 10"    /* CKDGIS.EXE */
      @option 23 = "IBM 8514/A"				     /* IBM8514A.EXE */
      @option 24 = "IBM Color Graphics Adapter"		     /* IBMCGA.EXE */
      @option 27 = "IBM Personal Systems/2 - MCGA"	     /* IBMMCGA.EXE */
      @option 28 = "IBM Personal Systems/2 - VGA"	     /* IBMVGA.EXE */
      @option 29 = "IBM Personal Systems/2 - VGA Small Font" /* IBMVGASM.EXE */
      @option 38 = "NEC MVA 1024"			     /* CKDGIS.EXE */
      @option 39 = "Number Nine Pepper Pro"		     /* CKTIGA.EXE */
      @option 40 = "Orchid ProDesigner VGA 16 color"	     /* ORCH16.EXE */
      @option 41 = "Orchid ProDesigner VGA 256 color"	     /* ORCH256.EXE */
      @option 44 = "Paradise VGA Professional 256 col"	     /* PAR256.EXE */
      @option 45 = "Paradise 8514/A Plus"		     /* WDI8514.EXE */
      @option 48 = "S3 86C911"				     /* CK_911.EXE */
      @option 50 = "STB VGA EM 16 color"		     /* STB16.EXE */
      @option 51 = "STB VGA EM 256 color"		     /* STB256.EXE */
      @option 55 = "TIGA compatibles"			     /* CKTIGA.EXE */
      @option 57 = "Tseng Labs ET4000 256 color"	     /* ET4000.EXE */
      @option 63 = "VESA compatible 16 color"		     /* VESA16.EXE */
      @option 64 = "VESA compatible 256 color"		     /* VESA256.EXE */
      @option 66 = "Video 7 VEGA VGA 16 color"		     /* V7VR16.EXE */
      @option 67 = "Video 7 VRAM VGA 16 color"		     /* V7VR16.EXE */
      @option 68 = "Video 7 VRAM VGA 256 color"		     /* V7VR256.EXE */
      
   @EndOption

   @If (!(( 1 [=@Option)|| ( 2 [=@Option)|| ( 3 [=@Option)|| ( 4 [=@Option)||
	  ( 5 [=@Option)|| ( 6 [=@Option)|| ( 7 [=@Option)|| ( 8 [=@Option)||
	  ( 9 [=@Option)|| (10 [=@Option)|| (11 [=@Option)|| (12 [=@Option)||
	  (13 [=@Option)|| (14 [=@Option)|| (15 [=@Option)|| (16 [=@Option)||
	  (17 [=@Option)|| (18 [=@Option)|| (19 [=@Option)|| (20 [=@Option)||
	  (21 [=@Option)|| (22 [=@Option)|| (23 [=@Option)|| (24 [=@Option)||
	  (25 [=@Option)|| (26 [=@Option)|| (27 [=@Option)|| (28 [=@Option)||
	  (29 [=@Option)|| (30 [=@Option)|| (31 [=@Option)|| (32 [=@Option)||
	  (33 [=@Option)|| (34 [=@Option)|| (35 [=@Option)|| (36 [=@Option)||
	  (37 [=@Option)|| (38 [=@Option)|| (39 [=@Option)|| (40 [=@Option)||
	  (41 [=@Option)|| (42 [=@Option)|| (43 [=@Option)|| (44 [=@Option)||
	  (45 [=@Option)|| (46 [=@Option)|| (47 [=@Option)|| (48 [=@Option)||
	  (49 [=@Option)|| (50 [=@Option)|| (51 [=@Option)|| (52 [=@Option)||
	  (53 [=@Option)|| (54 [=@Option)|| (55 [=@Option)|| (56 [=@Option)||
	  (57 [=@Option)|| (58 [=@Option)|| (59 [=@Option)|| (60 [=@Option)||
	  (61 [=@Option)|| (62 [=@Option)|| (63 [=@Option)|| (64 [=@Option)||
	  (65 [=@Option)|| (66 [=@Option)|| (67 [=@Option)|| (68 [=@Option)||
	  (69 [=@Option)|| (70 [=@Option)|| (71 [=@Option)))

       @GetOption
          @ClearOption (1000)
          @ClearOption (2000)
          @Move(5,5)
          @MoveCStr(5,5,79,"                                                                     ")
          @MoveCStr(6,5,79,"  You must use the space bar to select driver(s) to be installed.    ")
          @MoveCStr(7,5,79,"  The driver(s) you have selected will have a \"Yes\" next to them.    ")
          @MoveCStr(8,5,79,"  Then press the <Enter> key to begin installation.                  ")
          @MoveCStr(9,5,79,"                                                                     ")
          @MoveCStr(10,5,79,"  You may press the <Esc> key to abort installation.                 ")
          @MoveCStr(11,5,79,"                                                                     ")
           @LocalWindow (15,35)
           @option 1000 = "Select a Driver"
           @Option 2000 = "Install no Drivers"
       @EndOption

       @If (1000 [= @Option)

           @Goto driver
       
       @EndIf

   @EndIf
@EndIf
@If (@VideoCard == 'V')
   @If (@RAMAvail > 529000)
      @If (@System ("@StartupDrive:\\gifview @StartupDrive:\\regcard.gif"))
      @EndIf
   @EndIf
@EndIf
@DefineDisk

	@Label = "DISK 1 OF 8"

   @If ( 'D' [= @Group )
              
       @BeginLib DCADMAIN.RED  
                
           @File   *.*     @Out    \@Subdir\*.*
        
       @EndLib

       @BeginLib DCADFRM.RED
		
	    	@File   *.*	    @Out	\@Subdir\FRM\*.*

       @EndLib

   @EndIf

@EndDisk

@If (( 'E' [= @Group ) ||
     ( 'D' [= @Group ) ||
     ( 'H' [= @Group ))

   @Chain ("DISK 2 OF 8")

@ElseIf (( 'E' [= @Group ) ||
         ( 'D' [= @Group ))

   @Chain ("DISK 3 OF 8")

@ElseIf (( 'D' [= @Group ) ||
         ( 'C' [= @Group ) ||
         ( 'P' [= @Group ) ||
         ( 'U' [= @Group ))

   @Chain ("DISK 4 OF 8")

@ElseIf (( 'D' [= @Group ) ||
         ( 'H' [= @Group ))

   @Chain ("DISK 5 OF 8")

@ElseIf ( 'E' [= @Group )

   @Chain ("DISK 6 OF 8")

@ElseIf (( 'E' [= @Group ) ||
         ( 'V' [= @Group ))

   @Chain ("DISK 7 OF 8")

@ElseIf ( 'V' [= @Group )

   @Chain ("DISK 8 OF 8")

@EndIf

@Finish

   @If ('V' [= @Group)
   	@Mkdir ("@OutDrive3:\\@Subdir3\\VTM")
   @EndIf

   @Cls

	@ChDrive@OutDrive
        @ChDir "@Subdir"


   @If ('V' [= @Group)
       @If (!(100 [= @Option))
@Rename("@OutDrive3:\\@Subdir3\\CLIPPL64.EXE","CLIPPL.EXE")
@Rename("@OutDrive3:\\@Subdir3\\RDRPL640.EXE","RDRPL.EXE")
       @Else
@Rename("@OutDrive3:\\@Subdir3\\CLIPPLEM.EXE","CLIPPL.EXE")
@Rename("@OutDrive3:\\@Subdir3\\RDRPLEMS.EXE","RDRPL.EXE")
       @EndIf

   @EndIf
   @If (('A'[=@Group) || ('D'[= @Group) || ('U'[= @Group ))
        The DataCAD Configuration Utility will now be run.  This is
        where you should select your display device, digitizer (if any),
        plotter, etc.

        @If (('A'[=@Group) || ('D'[= @Group ))
           @Mkdir ("@OutDrive:\\@Subdir\\LYR")
           @Mkdir ("@OutDrive:\\@Subdir\\PLT")
           @Mkdir ("@OutDrive:\\@Subdir\\SYM")
           @Mkdir ("@OutDrive:\\@Subdir\\TPL")
        @EndIf
	@pause
   @If (@Spawn ("CONFIG"))
   @EndIf
   @EndIf
   @Cls

        The installation has been successfully completed.
        To run DataCAD, type RUNDCAD at the DOS prompt and
        press <Enter>.

	Note:  Please be sure you have installed your mouse
	       manufacturer's supplied driver according to
	       their instructions prior to running DataCAD.

	Thank-you for choosing DataCAD!

	@pause
@EndFinish


