I figure WPI is an excellent choice for installing the drivers/apps this way, I just need to be able to call WPI from the Windows installation while having it run from a different CD. After editing the WPI.cmd this is what I came up with:
I changed the CD-check file from WPI.ico to CD.txt to establish the %CDROM% variable. I did this because I need to check the drives/apps CD for the WPI.ico file to make sure the right CD is in the drive. Of course there will now have to be a CD.txt file at the root of both CDs.
REM Example, how to look for CDROM-drive. Must have WPI.ico at the root of the CD. for %%i in (C D E F G H I J K L M N O P Q R S T U V W X Y Z) do if exist %%i:\WPI.ico set CDROM=%%i: echo Found CD-Rom as drive %CDROM%
changed to:
REM Example, how to look for CDROM-drive. Must have CD.txt at the root of the CD. for %%i in (C D E F G H I J K L M N O P Q R S T U V W X Y Z) do if exist %%i:\CD.txt set CDROM=%%i: echo Found CD-Rom as drive %CDROM%
I then added these lines to check for the correct CD before continuing with WPI:
REM Determine if CD in CDROM-drive is WPI CD. :WPIcheck if exist %CDROM%:\WPI.ico goto WPI echo Please insert WPI CD in drive %CDROM%: pause goto WPIcheck :WPI
Lastly I changed wpipath to run from CD:
:WPI REM Determine the WPI startup path. REM if wpi should run off the cd the replace %~dp0 with %CDROM%. set wpipath=%CDROM%
That's it. Could some please double check my scripting to see if this will have the correct result?
Thanks in advance.



Help
Back to top








