home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware Overload
/
ShartewareOverload.cdr
/
windows
/
mmail2.zip
/
MARKMAIL.XWS
Wrap
Text File
|
1990-01-23
|
4KB
|
128 lines
/*
Crosstalk for Windows MarkMail PCBOARD Login Script.
Version 1.0 January 8th, 1990 3:19
Copyright (c) 1990 Guy Gallo
USAGE
This script allows you to completely automate the uploading
and downloading of message via MarkMail using Crosstalk for Windows.
(The script should be easily adapted to use Qmail or Qmail 3.0.
The script is loaded into the Setup.Session.Script field in the
following manner:
ScriptName parameter1 parameter2 parameter3
For Example:
MarkMail Mail Open 10
Translation:
Use the MarkMail script with the parameter "Mail", "Open", "10".
The above script entry ("MarkMail Mail Open 10") would tell the
script that yes, we are going to do mail transfer, and the mail door
is door number 10.
If you leave out the Mail keywork as a parameter then the script
functions as a slightly enhanced PCBoard logon.
For example, if you entered the script as
MarkMail Open 7
The script would simply open door number seven. Or
MarkMail N S U
The script would simply list the new files on the PCBoard and halt.
If you are tranferring mail it happens so:
Any reply file, if it exists, is uploaded *and then deleted*.
If a message file already exists on disk, it is renamed to
with "1" as the first character of the board name. For example,
THUNDER.QWK becomes 1HUNDER.QWK. If a saved file already exists
it is deleted.
Messages are downloaded and you are logged off.
*/
STRING RepName, QwkName, DirRep, DirQwk, SaveQwk, MailCmd, Cmd
MailCmd is Arg(2) + " " + Arg(3)
Cmd is Arg(1) + " " + Arg(2) + " " + Arg(3)
If UpCase(Arg(1)) is "MAIL" then Mail is True else Mail is False
--WE'RE DOING MAIL
RepName is NAME+".REP"
QwkName is NAME+".QWK"
DirRep is DirFil+"\"+RepName
DirQwk is DirFil+"\"+QwkName
SaveQwk is DirFil+"\"+inject(QwkName,"1",1)
--SET UP FILE NAMES
reply
wait 10 seconds for '=no?' : If TimeOut then GoTo WatchLoop
reply 'n q'
graphics on
--Minimize
--ENABLE THE ABOVE AFTER YOU'VE DETERMINED THAT THE SCRIPT WORKS
LABEL WatchLoop
reply
--THE ABOVE REPLY IS SO THAT YOU CAN ACTUALLY RUN THE SCRIPT AFTER
--YOU HAVE LOGGED ONTO A PCBOARD.
while online
watch for
'first name?' : wait 5 ticks : reply UserID+ " " + Password
'=no?',
'tinue?',
'tinue:',
'stop?',
'(NS)?',
'More?' : wait 5 ticks : reply
'=yes?' : wait 5 ticks : reply "N"
'(S)ystem, (Enter)=' : If Mail then Reply MailCmd else reply Cmd:...
Alarm : Halt
--FOR THE QUICK LOGON FOUND ON SOME PCBOARDS.
'Board Command? ' : If Mail then...
Reply MailCmd :...
Wait 10 Ticks else Reply Cmd : Alarm : Halt
--NORMAL MAIN BOARD COMMAND
'MarkMail Command?': Reply "D" : Goto GetPacket
--UPLOAD REPLY FILE IF THERE IS ONE.
--TELL MARKMAIL TO LOG OFF AFTER TRANSFER.
QUIET 5 MINUTES : bye : halt
endwatch
wend
LABEL GetPacket
Watch for
'[Y]es, [N]o, [G]oodbye When Done? ': Reply "Y" :...
Watch for
'(Ctrl-X) Aborts Transfer' : Gosub DoFiles : Receive QwkName : Alarm : Wait for 'Command' : Goto SendFiles
'Sorry, No Messages Found...' : Wait 10 for 'Command' : Goto SendFiles
endwatch
endwatch
LABEL SendFiles
If exists(DirRep) then{
Reply "U"
Wait 5 ticks
Send RepName
Delete DirRep
Message "Deleting reply file..."
Wait 10 For 'Command' : Reply "G" : Halt
}
else Reply "G" : Halt
LABEL DoFiles
If Exists(SaveQwk) then Delete SaveQwk
If Exists(DirQwk) then Rename DirQwk,SaveQwk
Return
end