Re: Zoomer hints?

barrym (barrym@neosoft.com)
Thu, 31 Aug 1995 12:41:52 -0500 (CDT)

On Wed, 30 Aug 1995, Nickels, Bob wrote:

> (BTW, how do you use ZDOS from batch files and "send" files using DOS path
> names?)
>
This is the batch file I use. I don't remember where I got it.
-----------------------------------------------------------------
@echo off
rem install c: 1 19200

if %1x==/?x goto usage
if %1x==?x goto usage
if %1x==helpx goto usage

:setup
set dkgdrv=c:
set dkgdest=\
set dkgport=1
set dkgbaud=19200
set dkgapp=%1
if not %1x==%dkgapp%x goto badenv

if not %2x==x set dkgdrv=%2

:install
echo Copying to %dkgdrv%%dkgdest% on COM%dkgport% at %dkgbaud% baud.
echo.

rem Setting destination drive and directory, and sending application

rem Setting Destination drive...
zdos /q /b:%dkgbaud% /p:%dkgport% /c %dkgdrv%
if errorlevel 1 goto badcomm

rem Setting destination directory...
zdos /q /b:%dkgbaud% /p:%dkgport% /c "cd %dkgdest%"
if errorlevel 1 goto badcomm

zdos /q /b:%dkgbaud% /p:%dkgport% /c "send %dkgapp%"
if errorlevel 1 goto badcomm

echo.
if errorlevel 1 goto badcomm
echo Transfer complete.
goto done

:badcomm
echo An error occurred in communications
goto done

:usage
echo Usage: 2z file dest
goto done

:badenv
echo Not enough environment space
goto done

:done
set dkgport=
set dkgbaud=
set dkgapp=
set dkgdest=
set dkgdrv=
echo.