| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | External Errorlevel |
Many of you are I am sure familiar with Binkley or similar FIDO
mailers. For those of you who are not, suffice to say that Bink is a mail
delivery program which sits in memory waiting for either mail bundles to
appear in its outbound directory, or for a call to come in from the modem.
It then wakes up and transfers the mail as needed. Obviously, no other
program can make use of the serial port while Bink is in charge. However,
Binkley has available a multi-errorlevel exit routine which produces an
exit with certain errorlevels upon certain circumstances - such as a
function key press. For example, Bink exits with an errorlevel of 10 if F1
is pressed, 20 if F2 is pressed, 30 if F3 is pressed, etc.
Now to the heart of the problem. A typical batch file for use with
a mailer like Binkley follows:
{at}echo off
:Bink
BTP Share Unattended
Iff Errorlevel 150 Then
BTP Share Mail
ElseIff Errorlevel 100 Then
pcplus
Elseiff Errorlevel 90 Then
aw
ElseIff Errorlevel 80 Then
call ppp.cmd
ElseIff Errorlevel 70 Then
term2
ElseIff Errorlevel 10 Then
goto Exit
Endiff
Goto Bink
:Exit
As you can see, Binkley (BTP) is running normally. Pressing F10
causes Bink to exit with errorlevel 100, which then causes PCPlus to run.
Pressing F9 causes PCAnywhere to run. Pressing F8 runs the PPP dialer.
Etc.
Great! So what's the problem? The problem is, I (and some of my
clients) would like to have an EXTERNAL event cause Bink to exit with
errorlevel 80 (or whatever). IOW, rather than opening up the Binkley
session, pressing F8, pressing to get back to the
desktop, and continuing, we would like to simply start a process which
causes Bink to exit and then do our internet stuff, whatever it is.
Exiting the internet dialer is a piece of cake. I simply run a kill
routine which looks for PPP.EXE and kills it. This done, the control is
passed back to the batch file, which then fires up Binkley again. Running
a kill process on BTP.EXE will sure enough stop Bink and give control back
to the batch file, but the errorlevel cannot be controlled, AFAIK. Is
there any way to EXTERNALLY force a process to close with a given
errorlevel? I have a keyboard stuffer routine here which might do the job,
but it is extremely clumsy, and doesn't work very well, and in addition the
author wants *WAY* too much for registering the product. Anyone have any
ideas?
Les
e-mail: lrhorer{at}fibrcom.com
--- EZPoint V2.2
* Origin: GUI? Ptui!!! --- Last Chance Pt 4 (1:387/800.4)SEEN-BY: 50/99 78/0 270/101 620/243 711/401 409 410 413 430 808 809 934 955 SEEN-BY: 712/407 515 517 628 713/888 800/1 7877/2808 2809 @PATH: 387/800 31 270/101 712/515 711/808 809 934 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.