set crisisdirprefix=
if %1.==/RDO. goto  setRDOdirprefix
if %1.==/rdo. goto  setRDOdirprefix
if %1.==/NORM. goto setNORMdirprefix
if %1.==/norm. goto setNORMdirprefix
if %1.==/OEMR. goto setOEMRdirprefix
if %1.==/oemr. goto setOEMRdirprefix
if %1.==/OEMW. goto setOEMWdirprefix
if %1.==/oemw. goto setOEMWdirprefix
goto loop

:setRDOdirprefix
set crisisdirprefix=rdo\
shift
goto loop

:setNORMdirprefix
set crisisdirprefix=norm\
shift
goto loop

:setOEMRdirprefix
set crisisdirprefix=oemr\
shift
goto loop

:setOEMWdirprefix
set crisisdirprefix=oemw\
shift
goto loop

:loop
	if '%1'=='' goto exit

	set crisisCurrentFile=%1
	if exist %crisisDriveName%\%crisisCurrentFile% goto next
	echo Copying the file "%crisisdirprefix%%crisisCurrentFile%"
	if not exist %crisisdirprefix%%crisisCurrentFile% goto cdDiskError
	xcopy /v %crisisdirprefix%%crisisCurrentFile% %crisisDriveName% >nul
	if ERRORLEVEL 1 goto cdDiskError

:next
	shift
	goto loop


:cdDiskError
	 if not exist %crisisdirprefix%%crisisCurrentFile% goto cdNoFile
	 if errorlevel 2 goto cdCpyBrk

rem======================================================================
rem
rem  Indicate that the copy process initialization failed.
rem
rem======================================================================
:cdMemErr
	echo.
	echo.
	echo !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
	echo.
	echo Error - Initialization error when copying "%crisisdirprefix%%crisisCurrentFile%",
	echo         the Disk was not created.  Free extra
	echo         conventional memory by removing any unneeded TSRs,
	echo         then try again.
	echo.
	echo !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
	echo.

	goto exit

rem======================================================================
rem
rem  Indicate that the file to copy was not found.
rem
rem======================================================================
:cdNoFile
	echo.
	echo.
	echo !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
	echo.
	echo Error - The file "%crisisdirprefix%%crisisCurrentFile%" was not found,
	echo         the Disk was not created. Check for the
	echo         file "%crisisdirprefix%%crisisCurrentFile%", then try again.
	echo.
	echo !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
	echo.

	goto exit


rem======================================================================
rem
rem  Indicate that the user interrupted the copy process.
rem
rem======================================================================
:cdCpyBrk
	echo.
	echo.
	echo !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
	echo.
	echo Error - The user interrupted while copying "%crisisdirprefix%%crisisCurrentFile%",
	echo         the Disk was not created.
	echo.
	echo !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
	echo.

:exit
