@echo off

if "%1"=="" goto errAdapNum

if exist %systemroot%\system32\drivers\flnk%1.sys goto errExists
if not exist \flnk1.sys goto errDisk

if exist \flnk2.sys del \flnk2.sys
if exist \flnk3.sys del \flnk3.sys
if exist \flnk4.sys del \flnk4.sys

echo.
echo When the network control panel applet has started, select
echo 'Add Adapter', then 3COM FDDI adapter %1. When asked for 
echo the installation directory, answer with the directory 
echo of the driver, e.g., A:\
echo.
pause

echo copy \flnk1.sys %systemroot%\system32\drivers\flnk%1.sys
copy \flnk1.sys %systemroot%\system32\drivers\flnk%1.sys
echo copy \flnk1.sys \flnk%1.sys
copy \flnk1.sys \flnk%1.sys
echo copy oemnadt%1.inf %systemroot%\system32
copy oemnadt%1.inf %systemroot%\system32
start control ncpa.cpl
goto end

:errAdapNum

echo.
echo INSTALL [234]
echo.
echo Please specify which adapter you are installing: 2, 3, or 4.
echo Note that you must install them in order, after the first adapter
echo has been successfully installed.
echo.
goto end

:errExists
echo.
echo The adapter driver %systemroot%\System32\drivers\flnk%1.SYS already exists.
echo.
goto end

:errDisk
echo.
echo The installation batch file INSTALL.BAT must be run from the
echo floppy drive where it exists.
echo.
goto end

:end
